Skip to content

Commit a5f71d7

Browse files
committed
test: refactoring
1 parent 560fe3a commit a5f71d7

File tree

1 file changed

+4
-12
lines changed

1 file changed

+4
-12
lines changed

test/reference-bundling.test.ts

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ describe('Reference bundling test', () => {
1313
const pkg = LocalRegistry.openPackage('reference-bundling/case2')
1414

1515
await expect(
16-
pkg.publish(pkg.packageId, {
17-
validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR },
18-
}),
16+
pkg.publish(pkg.packageId, { validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR } }),
1917
).rejects.toThrow(/does not exist/)
2018
})
2119

@@ -42,9 +40,7 @@ describe('Reference bundling test', () => {
4240
const pkg = LocalRegistry.openPackage('reference-bundling/case4')
4341

4442
await expect(
45-
pkg.publish(pkg.packageId, {
46-
validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR },
47-
}),
43+
pkg.publish(pkg.packageId, { validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR } }),
4844
).rejects.toThrow(/does not exist/)
4945
})
5046

@@ -61,9 +57,7 @@ describe('Reference bundling test', () => {
6157
const pkg = LocalRegistry.openPackage('reference-bundling/case5')
6258

6359
await expect(
64-
pkg.publish(pkg.packageId, {
65-
validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR },
66-
}),
60+
pkg.publish(pkg.packageId, { validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR } }),
6761
).rejects.toThrow(/references an invalid location/)
6862
})
6963

@@ -78,9 +72,7 @@ describe('Reference bundling test', () => {
7872
test('should throw on non-textual external reference', async () => {
7973
const pkg = LocalRegistry.openPackage('reference-bundling/case6')
8074
await expect(
81-
pkg.publish(pkg.packageId, {
82-
validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR },
83-
}),
75+
pkg.publish(pkg.packageId, { validationRulesSeverity: { brokenRefs: VALIDATION_RULES_SEVERITY_LEVEL_ERROR } }),
8476
).rejects.toThrow(/not a valid text file/)
8577
})
8678
})

0 commit comments

Comments
 (0)