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

Create a jest based runner #12

Open
4 tasks
3rd-Eden opened this issue May 22, 2019 · 3 comments
Open
4 tasks

Create a jest based runner #12

3rd-Eden opened this issue May 22, 2019 · 3 comments
Labels
enhancement New feature or request hardcore Requires extensive knowledge of a given subject runner Issues specific to test runners

Comments

@3rd-Eden
Copy link
Contributor

This ticket tracks the creation of a jest based runner. In order to integrate a test runner our system makes the following assumptions:

  • There is an API that can be required.
  • Importing of test files prepares or executes the tests.
  • There is an API, method that we can execute to run the tests or listen to test completion.
  • No child process / forking / spawning, or file system operation supported.

Currently jest executes the tests through their jest CLI. There is no programmatic API documented that we can use. This doesn't mean it's impossible to integrate. In the last few months, they started extracting bit's of the CLI into a dedicated jest-core package that would eventually become an API jestjs/jest#7696 this work is currently tracked in jestjs/jest#5048. When this work is completed it should become a lot easier to integrate jest as test runner.

Acceptance Criteria

  • Users can select jest as test runner.
  • Custom jest configuration can be supplied using --jest.{key} {value} CLI flags.
  • Example is added to our examples folder.
  • Documentation and new unit tests have been added.
@3rd-Eden 3rd-Eden added enhancement New feature or request hardcore Requires extensive knowledge of a given subject runner Issues specific to test runners labels May 22, 2019
@3rd-Eden 3rd-Eden pinned this issue May 23, 2019
@shwanton
Copy link

Adding jest runner support would be awesome!

Could React Native Testing Library be used even w/o the jest runner?

@3rd-Eden
Copy link
Contributor Author

@shwanton I haven't tried it yet, so I can't really comment on it. Have you given it a go?

@shwanton
Copy link

I have, but mostly for snapshot tests. However w/ RN there is still all the native mocks that need to happen so having it run in a real simulator sounds like a great solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request hardcore Requires extensive knowledge of a given subject runner Issues specific to test runners
Projects
None yet
Development

No branches or pull requests

2 participants