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

feat(experimentalIdentityAndAuth): add utilities for integration tests #1031

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

syall
Copy link
Contributor

@syall syall commented Oct 13, 2023

Issue #, if available:

N/A.

Description of changes:

Add utilities for integration tests:

  • update @httpApiKeyAuth integration tests to use integration test utilities
  • update @httpBearerAuth integration tests to use integration test utilities

If one or more of the packages in the /packages directory has been modified, be sure yarn changeset add has been run and its output has
been committed and included in this pull request. See CONTRIBUTING.md.


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@syall syall marked this pull request as ready for review October 13, 2023 08:16
@syall syall requested review from a team as code owners October 13, 2023 08:16
/**
* @internal
*/
export const expectClientCommand = async (input: any) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

input should be typed since it's used in a statically typed way below

const {
// Constructors
clientConstructor,
commandConstructor,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

type __<Client, Config, Command> = {
  clientConstructor: { new(config: Config): Client },
  commandConstructor: { new(): Command },
  defaultClientConfig?: Partial<Config>,
  clientConfig?: Partial<Config>,
  requestMatchers?: HttpRequestMatcher,
  contextExpectFn?: (c: HandlerExecutionContext): any,
  clientRejects?: string
}

hpmellema pushed a commit to hpmellema/smithy-typescript that referenced this pull request Nov 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants