Skip to content

Maintenance: Do Not Use an ESBuild Banner by Default in E2E tests #4715

@svozza

Description

@svozza

Summary

Our E2E tests use a CDK construct that by default has a workaround for certain bundling issues when using ES modules:

? `import { createRequire } from 'module';const require = createRequire(import.meta.url);`

This banner is necessary for some tests, particularly Tracer, but not all. We should remove this banner and see which tests actually require it or not.

Why is this needed?

This banner meant that we missed an issue when adding the InvokeStore to our utilities. This change will protect against any regressions

Which area does this relate to?

No response

Solution

Remove the banner and run the E2E tests and investigate whether any errors are due to bundling issues beyond our control (this is generally 3rd party dependencies that only ship with CJS build artefacts).

Acknowledgment

Future readers

Please react with 👍 and your use case to help us understand customer demand.

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmedThe scope is clear, ready for implementationinternalPRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.)testsPRs that add or change tests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions