[rspec-users] How does Spork help in requests specs?
Rodrigo Rosenfeld Rosas
lbocseg at yahoo.com.br
Fri May 18 00:04:23 UTC 2012
Even with Spork, my requests specs are very slow to start running (about
I suspect Rails is booting each time I run "rspec -X spec/requests".
Is that true? If so, is there any way I could instruct the web server to
keep alive after the specs run so that it would be faster on next run?
Are there any resources on how to have better performance on running
requests specs with Capybara and Webkit?
Having to wait about 7 seconds between consecutive runs is really a
blocker for me. If I can't get it to run faster, I'll give up on
requests specs and only have the controller's tests and client-side code
specs without any integration tests...
But to be honest, I feel much more comfortable having some integration
tests for the main features of my application and I would appreciate any
hints on making them start faster.
The last time I worked with Rails, long ago, it wasn't such a painful
experience to write such kind of tests (Capybara + Webkit). And my
current desktop PC is *way* faster than it used to be by that time...
I understand that Rails is much slower to boot now, but maybe there are
some tricks for reducing the need of rebooting between consecutive
requests specs run.
Thanks in advance,
More information about the rspec-users