Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: update vitest to 2.1.8 #6780

Merged
merged 4 commits into from
Jan 8, 2025
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion clients/client-s3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"extract:docs": "api-extractor run --local",
"generate:client": "node ../../scripts/generate-clients/single-service --solo s3",
"test": "yarn g:vitest run",
"test:browser": "node ./test/browser-build/esbuild && vitest run -c vitest.config.browser.ts --mode development",
"test:browser": "node ./test/browser-build/esbuild && yarn g:vitest run -c vitest.config.browser.ts --mode development",
"test:browser:watch": "node ./test/browser-build/esbuild && yarn g:vitest watch -c vitest.config.browser.ts",
"test:e2e": "yarn g:vitest run -c vitest.config.e2e.ts --mode development && yarn test:browser",
"test:e2e:watch": "yarn g:vitest watch -c vitest.config.e2e.ts",
Expand Down
7 changes: 2 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
"fs-extra": "^9.0.0",
"generate-changelog": "^1.7.1",
"glob": "7.1.6",
"happy-dom": "14.12.3",
"happy-dom": "16.3.0",
"husky": "^4.2.3",
"jest": "29.7.0",
"jmespath": "^0.15.0",
Expand All @@ -108,18 +108,15 @@
"turbo": "2.1.2",
"typescript": "~5.2.2",
"verdaccio": "5.25.0",
"vite": "4.5.5",
"vitest": "0.34.6",
"vitest": "2.1.8",
"webpack": "5.76.0",
"webpack-cli": "4.10.0",
"yargs": "17.5.1"
},
"overrides": {
"vite": "4.5.5",
"typescript": "~5.2.2"
},
"resolutions": {
"vite": "4.5.5",
"typescript": "~5.2.2"
},
"workspaces": {
Expand Down
8 changes: 4 additions & 4 deletions packages/credential-provider-ini/src/fromIni.integ.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ describe("fromIni region search order", () => {

await sts.getCallerIdentity({});
const credentials = await sts.config.credentials();
expect(credentials).toContain({
expect(credentials).toMatchObject({
accessKeyId: "STS_AR_ACCESS_KEY_ID",
secretAccessKey: "STS_AR_SECRET_ACCESS_KEY",
sessionToken: "STS_AR_SESSION_TOKEN_ap-northeast-1",
Expand All @@ -192,7 +192,7 @@ describe("fromIni region search order", () => {

await sts.getCallerIdentity({});
const credentials = await sts.config.credentials();
expect(credentials).toContain({
expect(credentials).toMatchObject({
accessKeyId: "STS_AR_ACCESS_KEY_ID",
secretAccessKey: "STS_AR_SECRET_ACCESS_KEY",
sessionToken: "STS_AR_SESSION_TOKEN_us-stsar-1",
Expand All @@ -214,7 +214,7 @@ describe("fromIni region search order", () => {

await sts.getCallerIdentity({});
const credentials = await sts.config.credentials();
expect(credentials).toContain({
expect(credentials).toMatchObject({
accessKeyId: "STS_AR_ACCESS_KEY_ID",
secretAccessKey: "STS_AR_SECRET_ACCESS_KEY",
sessionToken: "STS_AR_SESSION_TOKEN_ap-northeast-2",
Expand All @@ -238,7 +238,7 @@ describe("fromIni region search order", () => {

await sts.getCallerIdentity({});
const credentials = await sts.config.credentials();
expect(credentials).toContain({
expect(credentials).toMatchObject({
accessKeyId: "STS_AR_ACCESS_KEY_ID",
secretAccessKey: "STS_AR_SECRET_ACCESS_KEY",
sessionToken: "STS_AR_SESSION_TOKEN_us-east-1",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,7 @@ describe("bucketHostname", () => {
clientRegion: region,
isCustomEndpoint: false,
})
).toThrow("");
).toThrow();
});

it('should populate endpoint from MRAP ARN with access point name "myendpoint"', () => {
Expand Down
8 changes: 4 additions & 4 deletions packages/s3-presigned-post/src/createPresignedPost.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ describe("createPresignedPost", () => {
Bucket,
Key: "path/to/${filename}",
});
const { conditions } = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0]);
const { conditions } = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0] as any);
expect(conditions).toContainEqual(["starts-with", "$key", "path/to/"]);
});

Expand All @@ -112,7 +112,7 @@ describe("createPresignedPost", () => {
Bucket,
Key,
});
const policy = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0]);
const policy = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0] as any);
expect(policy).toMatchObject({
expiration: "2020-10-28T23:56:49Z",
});
Expand All @@ -125,7 +125,7 @@ describe("createPresignedPost", () => {
Key,
Expires: 7200,
});
expect(JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0])).toMatchObject({
expect(JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0] as any)).toMatchObject({
expiration: "2020-10-29T00:56:49Z",
});
});
Expand All @@ -139,7 +139,7 @@ describe("createPresignedPost", () => {
Fields: { acl: "public-read" },
});
expect(fields).toMatchObject({ bucket: Bucket, key: Key, acl: "public-read" });
const { conditions } = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0]);
const { conditions } = JSON.parse(mockS3Client.config.utf8Decoder.mock.calls[0] as any);
expect(conditions).toContainEqual({ acl: "public-read" });
});
});
Loading
Loading