Auto-test implies auto-save? Does anyone use auto-test like that?

Hi,

Using v3beta2, auto-save disabled in the settings page. When I enable the auto-test feature for running some specs, a trigger happy auto-save kicks in. This causes the specs to run continuously, failing often because the auto-save happens in mid-sentence, making my system unresponsive and draining my battery. Even stealing my focus every now and then.

Is my setup wrong or is anyone actually using it like this?

And how do I disable the autosave?

Tried to lookup the docs for this feature, but couldn't find more than a single sentence in the "Test Runner Tab" page.

Cheers,

Menno

10 comments

how do you use autotest? I use it on the command line with bundle exec autotest and it works perfectly. It doesn't trigger the tests unless I hit cmd+s. To speed up the tests, supplement it with spork, that should at least help some.

0

I use it on the command-line too, but wanted to see if running it within the IDE would be a good alternative. But with this auto-save it seems to be a no go.

So I'd be interested to learn what I'm overlooking (how to disable auto-save for example) or what's wrong with my setup.

0

*BUMP* Same issue here. Auto-test feature runs tests whenever I hit a key.

0

Try 'auto-test' mode for run configurations in RubyMine instead of autorenner gem.
https://img.skitch.com/20110823-rdy5db6kj2hifwmdwsiw7fg2e4.jpg

0

See the related discussion at issue RUBY-7630. Jetbrains deems it a feature. I personally think it's not much use the way it currently works.

0

Thank you Menno. Finally this weird thing makes sense. For some reason, I can't post to the Issue, so I'll post it here intstead:


@Dmitry: Please recognize that so far many people have spoken out against this design. I personally also find your auto-test completely unusable. As for the "never press Ctrl+S style", please don't try to change the way we work with computers. Would you agree that one of your biggest competitors is TextMate? Even though your focus is different, you see this comparison often on forums. TextMate, like most other IDE's work on the user saving files, not the program. This is true for Eclipse, NetBeans, Adobe Falsh Builder, and many others. You are alienating your users by telling them that the way they work is wrong.

Let me illustrate my workflow and grievances with your auto-test:
I save my file myself because that's when I have implemented changes that I am happy with, and would like to test, because now I think they work. Then my test takes 15-30 seconds. I am always finding that I have to wait for the test i *don't* want, to finish so that I am allowed to run the test i *do* want.

Please make this strange behaviour of auto-test into an optional feature that we as users can tick off very soon. I honestly thought it was a bug in your program.

0

Thank you Roman. My issues is actually with the RM auto-test feature. See my comment below.

0

Hello Søren,

Once again: What you actually want to do is to assign the Ctrl-S shortcut
to "run tests" action. This is a valid request, but it's not in any way auto-test.

Thank you Menno. Finally this weird thing makes sense. For some
reason, I can't post to the Issue, so I'll post it here intstead:

@Dmitry: Please recognize that so far many people have spoken out
against this design. I personally also find your auto-test completely
unusable. As for the "never press Ctrl+S style", please don't try to
change the way we work with computers. Would you agree that one of
your biggest competitors is TextMate? Even though your focus is
different, you see this comparison often on forums. TextMate, like
most other IDE's work on the user saving files, not the program. This
is true for Eclipse, NetBeans, Adobe Falsh Builder, and many others.
You are alienating your users by telling them that the way they work
is wrong.

Let me illustrate my workflow and grievances with your auto-test:

I save my file myself because that's when I have implemented changes
that I am happy with, and would like to test, because now I think they
work. Then my test takes 15-30 seconds. I am always finding that I
have to wait for the test i don't want, to finish so that I am
allowed to run the test i do want.

Please make this strange behaviour of auto-test into an optional
feature that we as users can tick off very soon. I honestly thought it
was a bug in your program.


--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Hi Dmitry
Thank you for your quick reply. I beg to differ on your definition of autotest, though. Auto-test is testing your files whenever they are changed. Auto-save is a whole different matter.

What I expect and would like of RM auto-test, is something along the lines of how guard (https://github.com/guard/guard) or autotest (https://github.com/grosser/autotest) works. A hook into FS Events that run my tests. But only when *I* save them. This is i.e. the exact way of operation that your auto-test has now, only without the auto-save feature.

I have now set up my workflow such that I only use RM auto-test on single features, which helps on the time to run the tests, however, I still find that the test never runs when my file is actually in a stable, testable mode. I am always waiting for the test to finish, and then inserting a space or something, to make it run again.

I have, however come across another problem, either with my file management, or the single cucumber feature run.

I have set up my cucumber features directory like this:

features
features->static_pages
features->step_definitions

If I add a feature, e.g. front_page.feature to the static_pages dir, the test of a single feature doesn't see the steps in features->step_definitions, but only features defined under features->static_pages->...
A complete cucumber test run of all features sees all the steps just fine, and my test works.

Can this step inclusion be changed in some way, or is there a different directory structure I can use that will let me reuse my shared steps?

0

the test of a single feature doesn't see the steps in features->step_definitions, but only features defined under features->static_pages->...
A complete cucumber test run of all features sees all the steps just fine, and my test works.

Can this step inclusion be changed in some way, or is there a different directory structure I can use that will let me reuse my shared steps?

Do you mean that you get undefined step error on runtime? If yes, then set working directory to RAILS_ROOT and add "-r feautres" to Runner options. It will help cucumber to find step definitions. You may save this settings in run configurations default settings for your project. See more details in discussion thread at http://devnet.jetbrains.net/thread/311201?tstart=30.

0

Please sign in to leave a comment.