Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ test-schema: bundles
test-integration: bundles
rm -rf ./clients/client-sso/node_modules/\@smithy # todo(yarn) incompatible redundant nesting.
yarn g:vitest run -c vitest.config.integ.mts
npx jest -c jest.config.integ.js
make test-protocols
make test-types
make test-endpoints
Expand Down
14 changes: 0 additions & 14 deletions jest.config.e2e.js

This file was deleted.

17 changes: 0 additions & 17 deletions jest.config.integ.js

This file was deleted.

22 changes: 10 additions & 12 deletions packages/credential-provider-http/src/fromHttp/fromHttp.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,6 @@ const credentials = {

const mockToken = "abcd";

const mockResponse = {
AccessKeyId: credentials.accessKeyId,
SecretAccessKey: credentials.secretAccessKey,
Token: credentials.sessionToken,
AccountId: "123",
Expiration: new Date(credentials.expiration).toISOString(), // rfc3339
};

const mockHandle = vi.fn().mockResolvedValue({
response: new HttpResponse({
statusCode: 200,
Expand All @@ -33,10 +25,16 @@ const mockHandle = vi.fn().mockResolvedValue({
});

vi.mock("@smithy/node-http-handler", () => ({
NodeHttpHandler: vi.fn().mockImplementation(() => ({
destroy: () => {},
handle: mockHandle,
})),
NodeHttpHandler: (() => {
const getImpl = () => ({
destroy: () => {},
handle: mockHandle,
});
const impl = Object.assign(vi.fn().mockImplementation(getImpl), {
create: () => getImpl(),
});
return impl;
})(),
streamCollector: vi.fn(),
}));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ Set AWS_CONTAINER_CREDENTIALS_FULL_URI or AWS_CONTAINER_CREDENTIALS_RELATIVE_URI
// throws if not to spec for provider.
checkUrl(url, options.logger);

const requestHandler = new NodeHttpHandler({
const requestHandler = NodeHttpHandler.create({
requestTimeout: options.timeout ?? 1000,
connectionTimeout: options.timeout ?? 1000,
});
Expand Down
4 changes: 0 additions & 4 deletions packages/credential-provider-node/jest.config.integ.js

This file was deleted.

5 changes: 3 additions & 2 deletions packages/credential-provider-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"test": "yarn g:vitest run",
"test:integration": "yarn g:jest -c jest.config.integ.js",
"test:watch": "yarn g:vitest watch"
"test:watch": "yarn g:vitest watch",
"test:integration": "yarn g:vitest run -c vitest.config.integ.mts",
"test:integration:watch": "yarn g:vitest watch -c vitest.config.integ.mts"
},
"keywords": [
"aws",
Expand Down
Loading
Loading