-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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 a key-press to re-run the specs under --watch #871
Comments
yeah a timeout sounds reasonable to me! |
+1 for this. |
How hard would adding a system event listener be? Maybe |
(@al-the-x why SIGINT? There's plenty of other signals that don't stomp on a user's ⌃C expectations. |
I agree that a different signal would be more appropriate: Maybe |
@al-the-x to most users, ⌃C isn't ‘send a signal to the program’, it's ‘get me out of this program to the place where I type other programs' names.’ And that's assuming they know that those two things are different. Hence my original suggestion of swallowing the space-bar or something; that's a more intuitive interface for the vast majority of users, than attempting to explain UNIX signals to them (or worse, stomping on possibly pre-existing expectations of being returned to the terminal, to do so) |
I have to agree with @ELLIOTTCABLE here. SIGINT means "interrupt," i.e. "mocha, f*ing kill yourself!"
Which is:
nodemon's approach might be best, i.e. typing |
IMO "watch" should be killed. There are other tools which do this sort of thing much better. |
+1 to kill watch. I don't see the point of replicating the functionality of a watcher inside the project, when any watcher tool will do the job. |
* Type "rs\n" to restart tests, fixes #871 Although the `--watch` feature is somewhat controversial (see #1780), is there any reason not to make it a little easier to use in the meantime? This adds nodemon's shortcut (`rs\n`) for manually restarting. * fix lint errors, add unit test * write to mochaProcess.stdin * Trigger travis build * add documentation * restore trailing whitespace * empty commit (to rerun tests)
I love --watch. It's great. But there's a few situations where I need to re-run the tests, and it doesn't catch them (i.e. changing an implementation file, as opposed to a test-file, see #870); it'd be nice if hitting the spacebar with the Terminal focused (or something along those lines) forced a re-run of the tests.
Along the same lines, it might be nice to be able to configure a minimum timeout to re-run them anyway, so that the window is always up-to-date, even if it misses a change. (Obviously more tenable for small projects than big ones … but isn't that already the case with
--watch
?)The text was updated successfully, but these errors were encountered: