Skip to content

Commit 28e1a8d

Browse files
authored
chore(functional): add tests for supported fips endpoints (#2931)
1 parent f73d2f1 commit 28e1a8d

File tree

3 files changed

+4227
-0
lines changed

3 files changed

+4227
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { join } from "path";
2+
3+
import testCases from "./test_cases_supported.json";
4+
5+
const getClientPackageName = (sdkId: string) =>
6+
`client-${sdkId
7+
.split(" ")
8+
.map((word) => word.toLowerCase())
9+
.join("-")}`;
10+
11+
describe("endpoints.fips", () => {
12+
for (const { sdkId, region, signingRegion, hostname } of testCases) {
13+
const clientPackageName = getClientPackageName(sdkId);
14+
it(`testing "${clientPackageName}" with region: ${region}`, async () => {
15+
const { defaultRegionInfoProvider } = await import(
16+
join("..", "..", "..", "..", "clients", clientPackageName, "src", "endpoints")
17+
);
18+
const regionInfo = await defaultRegionInfoProvider(region);
19+
expect(regionInfo.signingRegion).toEqual(signingRegion);
20+
expect(regionInfo.hostname).toEqual(hostname);
21+
});
22+
}
23+
});

0 commit comments

Comments
 (0)