Skip to content

Commit a592371

Browse files
committed
Makes the patchCommit tests less strict
1 parent 193fdbb commit a592371

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

packages/acceptance-tests/pkg-tests-specs/sources/commands/patchCommit.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ describe(`Commands`, () => {
7979
const manifest = await xfs.readJsonPromise(ppath.join(path, Filename.manifest));
8080

8181
expect(manifest.dependencies).toEqual({
82-
[`one-fixed-dep`]: `patch:one-fixed-dep@npm%3A1.0.0#~/.yarn/patches/one-fixed-dep-npm-1.0.0-b02516a4af.patch`,
82+
[`one-fixed-dep`]: expect.stringMatching(/^patch:one-fixed-dep/),
8383
});
8484

8585
expect(manifest).not.toHaveProperty(`resolutions`);
@@ -114,7 +114,7 @@ describe(`Commands`, () => {
114114
});
115115

116116
expect(manifest.resolutions).toEqual({
117-
[`no-deps@npm:1.0.0`]: `patch:no-deps@npm%3A1.0.0#~/.yarn/patches/no-deps-npm-1.0.0-cf533b267a.patch`,
117+
[`no-deps@npm:1.0.0`]: expect.stringMatching(/^patch:no-deps/),
118118
});
119119
}),
120120
);
@@ -143,7 +143,7 @@ describe(`Commands`, () => {
143143
const manifest = await xfs.readJsonPromise(ppath.join(path, Filename.manifest));
144144

145145
expect(manifest.dependencies).toEqual({
146-
[`one-fixed-dep`]: `patch:one-fixed-dep@npm%3A1.0.0#~/.yarn/patches/one-fixed-dep-npm-1.0.0-b02516a4af.patch`,
146+
[`one-fixed-dep`]: expect.stringMatching(/^patch:one-fixed-dep/),
147147
});
148148
}
149149

@@ -162,7 +162,7 @@ describe(`Commands`, () => {
162162
const manifest = await xfs.readJsonPromise(ppath.join(path, Filename.manifest));
163163

164164
expect(manifest.dependencies).toEqual({
165-
[`one-fixed-dep`]: `patch:one-fixed-dep@npm%3A1.0.0#~/.yarn/patches/one-fixed-dep-npm-1.0.0-b02516a4af.patch`,
165+
[`one-fixed-dep`]: expect.stringMatching(/^patch:one-fixed-dep/),
166166
});
167167
}
168168
}),
@@ -196,7 +196,7 @@ describe(`Commands`, () => {
196196
});
197197

198198
expect(manifest.resolutions).toEqual({
199-
[`peer-deps-lvl1@npm:1.0.0`]: `patch:peer-deps-lvl1@npm%3A1.0.0#~/.yarn/patches/peer-deps-lvl1-npm-1.0.0-894d37389e.patch`,
199+
[`peer-deps-lvl1@npm:1.0.0`]: expect.stringMatching(/^patch:peer-deps-lvl1/),
200200
});
201201
}),
202202
);

0 commit comments

Comments
 (0)