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

test: unit and type tests for createPages #692

Merged
merged 6 commits into from
May 3, 2024

Conversation

pmelab
Copy link
Contributor

@pmelab pmelab commented May 2, 2024

I have not yet found a way to add type-tests for CreatePage and CreateLayout. Since the generic is on the function and not on the argument, the path property always resolves to never. I'm not sure if a test is even possible in this case. Any suggestions are welcome.

Copy link

vercel bot commented May 2, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
waku ✅ Ready (Inspect) Visit Preview May 3, 2024 6:50am

Copy link

codesandbox-ci bot commented May 2, 2024

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.

@dai-shi
Copy link
Owner

dai-shi commented May 3, 2024

How about something like 403f477 ?

@pmelab
Copy link
Contributor Author

pmelab commented May 3, 2024

How about something like 403f477 ?

Haha, yeah obviously. I was tunnel-visioned on ts-expect.

@dai-shi
Copy link
Owner

dai-shi commented May 3, 2024

Same. I thought about using TypeEqual first.

Copy link
Owner

@dai-shi dai-shi left a comment

Choose a reason for hiding this comment

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

It looks good overall. Let me know when it's ready to merge.

@pmelab
Copy link
Contributor Author

pmelab commented May 3, 2024

It looks good overall. Let me know when it's ready to merge.

Lets go!

@dai-shi dai-shi merged commit 6fd1b25 into dai-shi:main May 3, 2024
28 checks passed
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