Skip to content

[EngSys] Use tsx for min/max testing#28890

Merged
maorleger merged 1 commit intoAzure:mainfrom
maorleger:update-dependency-testing-to-tsx
Mar 12, 2024
Merged

[EngSys] Use tsx for min/max testing#28890
maorleger merged 1 commit intoAzure:mainfrom
maorleger:update-dependency-testing-to-tsx

Conversation

@maorleger
Copy link
Copy Markdown
Member

Packages impacted by this PR

N/A

Issues associated with this PR

Build failures

Describe the problem that is addressed by this PR

esm is slowly becoming a larger problem for us and we've been on a mission to
remove it. min/max tests fail because esm is unable to handle safe-navigation
operators (?.)

While a separate PR switches tests to use tsx, this PR focuses on min/max tests
and can be merged separately.

Provide a list of related PRs (if any)

#28826

@maorleger
Copy link
Copy Markdown
Member Author

/azp run js - ai-document-intelligence-rest - tests

@maorleger maorleger mentioned this pull request Mar 12, 2024
1 task
@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@maorleger maorleger marked this pull request as ready for review March 12, 2024 17:24
@maorleger maorleger requested review from mpodwysocki and xirzec March 12, 2024 17:25
"build": "tsc -p .",
"integration-test:browser": "karma start --single-run",
"integration-test:node": "mocha -r esm-workaround.js -r esm --require source-map-support/register --reporter mocha-multi-reporter.js --reporter-option output=test-results.xml --timeout 350000 --full-trace \"dist-esm/**/{,!(browser)/**/}*.spec.js\" --exit",
"integration-test:node": "mocha --require tsx --require source-map-support/register --reporter mocha-multi-reporter.js --reporter-option output=test-results.xml --timeout 350000 --full-trace \"dist-esm/**/{,!(browser)/**/}*.spec.js\" --exit",
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should esm-workaround.js be removed as part of this update?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Good Q, it's used for min/max testing and (as of now) for package integration testing. We're working on removing all of this but it'll be a few steps of work:

  1. Merge this PR
  2. Merge remove use-esm-workaround #28826
  3. Let things bake and ensure nightly builds are happy, min/max is happy, etc
  4. Remove esm-workaround.js
  5. Remove esm as a dependency from all our packages in a NO_CI commit

I think that would cover it

@maorleger
Copy link
Copy Markdown
Member Author

/check-enforcer evaluate

@maorleger maorleger merged commit c2c7d17 into Azure:main Mar 12, 2024
@maorleger maorleger deleted the update-dependency-testing-to-tsx branch March 12, 2024 18:41
@maorleger maorleger mentioned this pull request Mar 12, 2024
11 tasks
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.

3 participants