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

Add typegen tests for never computed for eventsCausing* and invokeSrcNameMap #2996

Merged
merged 1 commit into from
Feb 24, 2022

Conversation

Andarist
Copy link
Member

Just adding tests to ensure that this kind of generated output would work with the current type machinery

related to statelyai/xstate-tools#411

@Andarist Andarist requested a review from mattpocock January 31, 2022 10:22
@changeset-bot
Copy link

changeset-bot bot commented Jan 31, 2022

⚠️ No Changeset found

Latest commit: 908c065

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ghost
Copy link

ghost commented Jan 31, 2022

CodeSee Review Map:

Review these changes using an interactive CodeSee Map

Review in an interactive map

View more CodeSee Maps

Legend

CodeSee Map Legend

@codesandbox-ci
Copy link

codesandbox-ci bot commented Jan 31, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 908c065:

Sandbox Source
XState Example Template Configuration
XState React Template Configuration

@Andarist
Copy link
Member Author

This is weird... my VSCode says this is OK but CI and my local yarn dev complain in the same way.

I've figured out the difference is in strictNullChecks:

We need to unify the compilation settings in the future, in the meantime, I would not merge this PR - but the point is, the error is reported correctly in both cases. It's just a slightly different error and it's reported in a slightly different location. I think it still makes sense to output those nevers in the typegen. cc @mattpocock

@Andarist Andarist force-pushed the andarist/add-typegen-tests-for-never-values branch from 4bf0e45 to 908c065 Compare February 23, 2022 15:35
@Andarist
Copy link
Member Author

Since I've migrated out test suite to use the strict mode - the reported errors should be consistent now.

@Andarist Andarist merged commit 1aaf509 into main Feb 24, 2022
@Andarist Andarist deleted the andarist/add-typegen-tests-for-never-values branch February 24, 2022 06:17
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