question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add out-of-the-box support for type tests

See original GitHub issue

Current Behavior

tsdx allows me to test my code using Jest out of the box. That’s great. But I wish I could test my types as well.

Desired Behavior

Out-of-the-box support for testing types using dtslint or similar library.

Suggested Solution

  1. Introduce dtslint, ts-expect or a similar library to all tsdx templates.
  2. Create a directory for type tests.
  3. Run type tests when the default test task is run.

Who does this impact? Who is this for?

All users. tsdx is TypeScript-oriented, and unit-testing types helps preventing accidental breaking changes in these.

Describe alternatives you’ve considered

A guide explaining how one can test their types in a project bootstrapped with tsdx.

Additional context

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:3
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
karol-majewskicommented, Feb 1, 2021

@KATT I ended up using dtslint.

0reactions
MrLohcommented, Feb 9, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

nx test: Jest unit tests are failing to run in any test that ... - GitHub
Current Behavior An NX - Ionic and Vue workspace fails to run tests, many solutions tested and any seems to fix the issue:...
Read more >
Thinking Out of the Box While Testing Software
In this article, learn a few software testing tips that will help you test your application effectively and timely.
Read more >
Testing - Spring
This chapter covers Spring's support for integration testing and best practices for unit testing. The Spring team advocates test-driven ...
Read more >
Have Testing added to the Deployment Type drop-dow...
Please help in how to do that Request is to have Testing added to the Deployment Type drop-down list on the Hardware Asset...
Read more >
React Testing Library
React Testing Library builds on top of DOM Testing Library by adding APIs for working with React components. Projects created with Create React ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found