mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 07:47:39 +00:00
test: dedupe repeated validation and throw assertions
This commit is contained in:
@@ -142,8 +142,8 @@ describe("resolveConfigIncludes", () => {
|
||||
for (const testCase of cases) {
|
||||
const files = { [configPath(testCase.includeFile)]: testCase.included };
|
||||
const obj = { $include: `./${testCase.includeFile}`, extra: true };
|
||||
expect(() => resolve(obj, files), testCase.includeFile).toThrow(ConfigIncludeError);
|
||||
expect(() => resolve(obj, files), testCase.includeFile).toThrow(
|
||||
expectResolveIncludeError(
|
||||
() => resolve(obj, files),
|
||||
/Sibling keys require included content to be an object/,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user