Skip to content

Commit a4dd61a

Browse files
committed
Fixed broken integration tests
Tests broke due to changes in error string formats in CloudFormation
1 parent 8d4854b commit a4dd61a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tst/integration.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ async function createStackAndExpectFailure(
201201
(event) => event.ResourceStatus === "CREATE_FAILED"
202202
).map((event) => event.ResourceStatusReason);
203203

204-
expect(reasons).toContain(expectedFailureReason);
204+
expect(reasons).toContainEqual(expect.stringContaining(expectedFailureReason));
205205
}
206206

207207
describe("all tests", () => {
@@ -302,7 +302,7 @@ describe("all tests", () => {
302302
sourceRoot,
303303
generatedCloudFormationTemplateFile,
304304
{ BucketName: rootBucketName, ObjectPrefix: "" },
305-
"Failed to create resource. Bucket must be empty"
305+
"Received response status [FAILED] from custom resource. Message returned: Bucket must be empty"
306306
);
307307
},
308308
ASYNC_TIMEOUT_MS
@@ -320,7 +320,7 @@ describe("all tests", () => {
320320
path.join(exampleRoot, "invalid-s3uploadconfig-src"),
321321
generatedCloudFormationTemplateFile,
322322
{},
323-
"Failed to create resource. Unable to read or parse .s3uploadconfig.json: SyntaxError: Unexpected token T in JSON at position 0"
323+
"Received response status [FAILED] from custom resource. Message returned: Unable to read or parse .s3uploadconfig.json: SyntaxError: Unexpected token T in JSON at position 0"
324324
);
325325
},
326326
ASYNC_TIMEOUT_MS

0 commit comments

Comments
 (0)