Skip to content

chore(tests): split custom Vitest matchers out of setupEnv - #5704

Merged
svozza merged 2 commits into
mainfrom
chore/5697-split-matchers
Sep 13, 2026
Merged

svozza merged 2 commits into
mainfrom
chore/5697-split-matchers

Conversation

@svozza

@svozza svozza commented Sep 12, 2026

Copy link
Copy Markdown
Contributor

Summary

Move the AWS SDK, Logger, and Metrics matchers out of the shared test setup, keeping each family's implementation alongside its assertion typings. Existing matcher behavior and the shared setupEnv.ts entry point are preserved.

Changes

  • Group the seven custom matchers into awsSdk.ts, logger.ts, and metrics.ts under packages/testing/src/matchers/.
  • Combine the matcher families and Vitest type augmentation in matchers/index.ts, with registration performed by setupEnv.ts.
  • Update the coding standards to reference the new matcher location.
  • Validate matcher type tests, workspace type checks, linting, and the full unit suite with 100% coverage.

Issue number: closes #5697


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

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

Move the AWS SDK, Logger and Metrics matchers into one module each
under packages/testing/src/matchers, keeping each family's
implementation next to its assertion typings. setupEnv keeps its path
and only registers the merged object.
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation Bot added the size/XL PRs between 500-999 LOC, often PRs that grown with feedback label Sep 12, 2026
@svozza
svozza merged commit 0fe17a0 into main Sep 13, 2026
41 checks passed
@svozza
svozza deleted the chore/5697-split-matchers branch September 13, 2026 11:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XL PRs between 500-999 LOC, often PRs that grown with feedback

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Maintenance: split custom Vitest matchers out of setupEnv.ts

2 participants