-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Run individual Detox test #536
Comments
It may be a good idea to passthrough command line arguments to test runners. |
OK great, I will investigate! (I meant to say that.) This feels like it'd be an easier PR to start with than my #518 proposa. |
This is needed by our team as well! |
you can use cucumber like i did for as the test runner. with Cucumber, there is a tag for the scenario and therefore can run your specific test case with the tag. |
My team could also use this |
just curious to understand pros and cons of passing this particular flag to the test runners vs just overriding testFolder, like this, if anyone has insight |
This is something that I think is really important to have given how long some of the tests can take to run. |
arbitrary command-line arguments from |
This'd be a real time-saver :) |
Would be great if this is supported soon :) |
Update to anyone who finds this issue, I've ended up less available than I thought. Anyone else is welcome to pick up this issue. In the meantime in Mocha using |
+1 |
another temporary workaround is you can edit the e2e/mocha.opts, and add a |
Has work been started on this? If not, I will start working on it. |
I haven't started work on this or heard of anyone who has. FYI though this PR implements something related that is Jest-specific. It's probably worth looking into how it's implemented to see if this issue is still needed: #1083 |
Seems like a solution has already been implemented in #1025. Though it hasn't been released yet. Does anyone know the release schedule? |
There's currently a way to run a single test.. e.g. |
@jeremyeaton89 Nice, thanks for adding us and for letting us know! I'm closing this issue as the |
Running
detox test
runs all tests in the suite. Is there a way to run a subset of the tests? A single test file, or a single test case.I've configured Detox to use Mocha as the test runner, as per the docs. I know that Mocha has a
-g
option to specify a pattern for the tests to run. But options passed to thedetox
command don't seem to be passed along tomocha
(which makes sense):I can use Mocha's
.only()
function to designate oneit()
ordescribe()
to run—but that involves changes in the source code. It would be great if I could have the option to use a command-line argument to specify which test to run instead. That would certainly be test-runner-specific, of course—so I think providing a way to pass arbitrary command-line arguments fromdetox test
along to the test could be good.I'm attempting to use Detox for TDD, and the quicker the feedback I can get, the better. As my test suite grows, it would become less and less motivating to run tests as I develop if the time to run gets longer and longer.
The text was updated successfully, but these errors were encountered: