Skip to content

Commit 3e8d473

Browse files
authored
test: adjust yarn lock parser case names to match parser function name (#127)
1 parent 6a5cb80 commit 3e8d473

File tree

2 files changed

+17
-17
lines changed

2 files changed

+17
-17
lines changed

pkg/lockfile/parse-yarn-lock-v1_test.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ func TestParseYarnLock_v1_FileDoesNotExist(t *testing.T) {
1414
expectPackages(t, packages, []lockfile.PackageDetails{})
1515
}
1616

17-
func TestYarnLock_v1_NoPackages(t *testing.T) {
17+
func TestParseYarnLock_v1_NoPackages(t *testing.T) {
1818
t.Parallel()
1919

2020
packages, err := lockfile.ParseYarnLock("fixtures/yarn/empty.v1.lock")
@@ -26,7 +26,7 @@ func TestYarnLock_v1_NoPackages(t *testing.T) {
2626
expectPackages(t, packages, []lockfile.PackageDetails{})
2727
}
2828

29-
func TestYarnLock_v1_OnePackage(t *testing.T) {
29+
func TestParseYarnLock_v1_OnePackage(t *testing.T) {
3030
t.Parallel()
3131

3232
packages, err := lockfile.ParseYarnLock("fixtures/yarn/one-package.v1.lock")
@@ -44,7 +44,7 @@ func TestYarnLock_v1_OnePackage(t *testing.T) {
4444
})
4545
}
4646

47-
func TestYarnLock_v1_TwoPackages(t *testing.T) {
47+
func TestParseYarnLock_v1_TwoPackages(t *testing.T) {
4848
t.Parallel()
4949

5050
packages, err := lockfile.ParseYarnLock("fixtures/yarn/two-packages.v1.lock")
@@ -67,7 +67,7 @@ func TestYarnLock_v1_TwoPackages(t *testing.T) {
6767
})
6868
}
6969

70-
func TestYarnLock_v1_MultipleVersions(t *testing.T) {
70+
func TestParseYarnLock_v1_MultipleVersions(t *testing.T) {
7171
t.Parallel()
7272

7373
packages, err := lockfile.ParseYarnLock("fixtures/yarn/multiple-versions.v1.lock")
@@ -100,7 +100,7 @@ func TestYarnLock_v1_MultipleVersions(t *testing.T) {
100100
})
101101
}
102102

103-
func TestYarnLock_v1_MultipleConstraints(t *testing.T) {
103+
func TestParseYarnLock_v1_MultipleConstraints(t *testing.T) {
104104
t.Parallel()
105105

106106
packages, err := lockfile.ParseYarnLock("fixtures/yarn/multiple-constraints.v1.lock")
@@ -123,7 +123,7 @@ func TestYarnLock_v1_MultipleConstraints(t *testing.T) {
123123
})
124124
}
125125

126-
func TestYarnLock_v1_ScopedPackages(t *testing.T) {
126+
func TestParseYarnLock_v1_ScopedPackages(t *testing.T) {
127127
t.Parallel()
128128

129129
packages, err := lockfile.ParseYarnLock("fixtures/yarn/scoped-packages.v1.lock")
@@ -146,7 +146,7 @@ func TestYarnLock_v1_ScopedPackages(t *testing.T) {
146146
})
147147
}
148148

149-
func TestYarnLock_v1_VersionsWithBuildString(t *testing.T) {
149+
func TestParseYarnLock_v1_VersionsWithBuildString(t *testing.T) {
150150
t.Parallel()
151151

152152
packages, err := lockfile.ParseYarnLock("fixtures/yarn/versions-with-build-strings.v1.lock")
@@ -184,7 +184,7 @@ func TestYarnLock_v1_VersionsWithBuildString(t *testing.T) {
184184
})
185185
}
186186

187-
func TestYarnLock_v1_Commits(t *testing.T) {
187+
func TestParseYarnLock_v1_Commits(t *testing.T) {
188188
t.Parallel()
189189

190190
packages, err := lockfile.ParseYarnLock("fixtures/yarn/commits.v1.lock")
@@ -305,7 +305,7 @@ func TestYarnLock_v1_Commits(t *testing.T) {
305305
})
306306
}
307307

308-
func TestYarnLock_v1_Files(t *testing.T) {
308+
func TestParseYarnLock_v1_Files(t *testing.T) {
309309
t.Parallel()
310310

311311
packages, err := lockfile.ParseYarnLock("fixtures/yarn/files.v1.lock")

pkg/lockfile/parse-yarn-lock-v2_test.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ func TestParseYarnLock_v2_FileDoesNotExist(t *testing.T) {
1414
expectPackages(t, packages, []lockfile.PackageDetails{})
1515
}
1616

17-
func TestYarnLock_v2_NoPackages(t *testing.T) {
17+
func TestParseYarnLock_v2_NoPackages(t *testing.T) {
1818
t.Parallel()
1919

2020
packages, err := lockfile.ParseYarnLock("fixtures/yarn/empty.v2.lock")
@@ -26,7 +26,7 @@ func TestYarnLock_v2_NoPackages(t *testing.T) {
2626
expectPackages(t, packages, []lockfile.PackageDetails{})
2727
}
2828

29-
func TestYarnLock_v2_OnePackage(t *testing.T) {
29+
func TestParseYarnLock_v2_OnePackage(t *testing.T) {
3030
t.Parallel()
3131

3232
packages, err := lockfile.ParseYarnLock("fixtures/yarn/one-package.v2.lock")
@@ -44,7 +44,7 @@ func TestYarnLock_v2_OnePackage(t *testing.T) {
4444
})
4545
}
4646

47-
func TestYarnLock_v2_TwoPackages(t *testing.T) {
47+
func TestParseYarnLock_v2_TwoPackages(t *testing.T) {
4848
t.Parallel()
4949

5050
packages, err := lockfile.ParseYarnLock("fixtures/yarn/two-packages.v2.lock")
@@ -67,7 +67,7 @@ func TestYarnLock_v2_TwoPackages(t *testing.T) {
6767
})
6868
}
6969

70-
func TestYarnLock_v2_MultipleVersions(t *testing.T) {
70+
func TestParseYarnLock_v2_MultipleVersions(t *testing.T) {
7171
t.Parallel()
7272

7373
packages, err := lockfile.ParseYarnLock("fixtures/yarn/multiple-versions.v2.lock")
@@ -95,7 +95,7 @@ func TestYarnLock_v2_MultipleVersions(t *testing.T) {
9595
})
9696
}
9797

98-
func TestYarnLock_v2_ScopedPackages(t *testing.T) {
98+
func TestParseYarnLock_v2_ScopedPackages(t *testing.T) {
9999
t.Parallel()
100100

101101
packages, err := lockfile.ParseYarnLock("fixtures/yarn/scoped-packages.v2.lock")
@@ -123,7 +123,7 @@ func TestYarnLock_v2_ScopedPackages(t *testing.T) {
123123
})
124124
}
125125

126-
func TestYarnLock_v2_VersionsWithBuildString(t *testing.T) {
126+
func TestParseYarnLock_v2_VersionsWithBuildString(t *testing.T) {
127127
t.Parallel()
128128

129129
packages, err := lockfile.ParseYarnLock("fixtures/yarn/versions-with-build-strings.v2.lock")
@@ -151,7 +151,7 @@ func TestYarnLock_v2_VersionsWithBuildString(t *testing.T) {
151151
})
152152
}
153153

154-
func TestYarnLock_v2_Commits(t *testing.T) {
154+
func TestParseYarnLock_v2_Commits(t *testing.T) {
155155
t.Parallel()
156156

157157
packages, err := lockfile.ParseYarnLock("fixtures/yarn/commits.v2.lock")
@@ -206,7 +206,7 @@ func TestYarnLock_v2_Commits(t *testing.T) {
206206
})
207207
}
208208

209-
func TestYarnLock_v2_Files(t *testing.T) {
209+
func TestParseYarnLock_v2_Files(t *testing.T) {
210210
t.Parallel()
211211

212212
packages, err := lockfile.ParseYarnLock("fixtures/yarn/files.v2.lock")

0 commit comments

Comments
 (0)