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

Upgrade to Langium 2.1.3 #40

Merged
merged 2 commits into from
Nov 24, 2023
Merged

Upgrade to Langium 2.1.3 #40

merged 2 commits into from
Nov 24, 2023

Conversation

martin-fleck-at
Copy link
Collaborator

Langium > 2.0.0 only supports ESM so we refactor the extension to ESM

Setup Changes

  • Set type to 'module' in package.json and update configs accordingly
  • Use esbuild to develop in ESM but compile to CJS for VSX

Code Changes

  • Adapt all relative imports to use '.js' extension (even for '.ts')
  • Remove now obsolete adaptations of workspace manager

Test Changes

  • Provide custom Jest configuration for ES modules
  • Use 'jest.useFakeTimers()' as specified in Jest documentation for ESM
  • Add '--experimental-vm-modules' Node flag to ESM test executions
  • Add 'NODE_NO_WARNINGS' environment variable to ignore ESM warning
  • Use unique report file names as we need to run twice (CJS, ESM)
  • Add display name to all test configs for nicer output
  • Adapt launch configs to properly debug single test or all tests

Langium > 2.0.0 only supports ESM so we refactor the extension to ESM

Setup Changes
- Set type to 'module' in package.json and update configs accordingly
- Use esbuild to develop in ESM but compile to CJS for VSX

Code Changes
- Adapt all relative imports to use '.js' extension (even for '.ts')
- Remove now obsolete adaptations of workspace manager

Test Changes
- Provide custom Jest configuration for ES modules
- Use 'jest.useFakeTimers()' as specified in Jest documentation for ESM
- Add '--experimental-vm-modules' Node flag to ESM test executions
- Add 'NODE_NO_WARNINGS' environment variable to ignore ESM warning
- Use unique report file names as we need to run twice (CJS, ESM)
- Add display name to all test configs for nicer output
- Adapt launch configs to properly debug single test or all tests
Copy link

github-actions bot commented Nov 24, 2023

Unit Test Results

    3 files  ±0    30 suites  ±0   2m 23s ⏱️ +43s
  68 tests ±0    68 ✔️ ±0  0 💤 ±0  0 ±0 
207 runs  ±0  207 ✔️ ±0  0 💤 ±0  0 ±0 

Results for commit 2c4dba6. ± Comparison against base commit b94137d.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@harmen-xb harmen-xb left a comment

Choose a reason for hiding this comment

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

All in all looks good to me, just some small questions in comments.

Copy link
Contributor

@harmen-xb harmen-xb left a comment

Choose a reason for hiding this comment

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

All looks good now!

@harmen-xb harmen-xb merged commit 9afb1c3 into main Nov 24, 2023
5 checks passed
@harmen-xb harmen-xb deleted the feature/upgrade-langium branch November 24, 2023 21:11
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