Questions tagged [autotest]

Autotest is a Ruby gem for running tests automatically when source files change.

272 questions
4
votes
1 answer

Using Autotest in the Simplest Possible Way

I'm new to using Autotest to continuously run rspec specs. I'd like to simply use Autotest to work with two files: [filename].rb and [filename]_spec.rb, but when I run Autotest in the directory those files are in, it doesn't pick up changes. What…
Aeden
  • 195
  • 9
3
votes
1 answer

autotest does not work with rspec shared examples

My tests look like this: <<< spec/models/user_shared.rb shared_examples_for "a user" do end <<< spec/models/worker_spec.rb require 'spec_helper' require 'models/user_shared' describe Worker do it_behaves_like "a user" end I can run rspec spec…
Markus
  • 5,667
  • 4
  • 48
  • 64
3
votes
2 answers

Rails 3 + Rspec 2 + Autotest: Autotest style Rspec2 doesn't seem to exist?

I updated my ruby gem and suddenly Autotest stopped to work.. After many attempts to fix without any debug information, I know have this: $ autotest loading autotest/rails_rspec2 You don't have i18n installed in your application. Please add it to…
Donald
  • 243
  • 4
  • 10
3
votes
1 answer

Getting Autotest to work with Cucumber

I'm trying to setup autotest to work with cucumber but despite following the tutorials it always finishes with: 0 tests, 0 assertions, 0 failures, 0 errors I see from this blog post that I need to add something:…
AnApprentice
  • 108,152
  • 195
  • 629
  • 1,012
3
votes
2 answers

Autotest ruby on rails with rspec

I'm using autotest with ruby on rails. I have passing 2 passing tests when I run. rspec spec/; however, when I try to use autotest this is the output: matt@matt-laptop:~/sample_app$ autotest loading autotest/rails_rspec2 style:…
Matt Phillips
  • 11,249
  • 10
  • 46
  • 71
3
votes
4 answers

Validation problem with Autotest and Factory Girl

i have a problem with Autotest. In my user model are the username & email address unique. When i start Autotest everything works fine. In the secound round, from autotest, i have a Validation failed: Email has already been taken, Username has…
ThreeFingerMark
  • 989
  • 3
  • 12
  • 21
3
votes
2 answers

Autotest, RSpec 2 and Ruby 1.9.2-p0 - no output at all

I have started the book Continuous Testing with Ruby (B2.0 printing), but am running into immediate problems. Per the first chapter, I have created an empty Gem using Jeweler 1.5.1 $ jeweler --rspec twits Running the specs manually with rake gives…
Mike Furtak
  • 1,105
  • 1
  • 11
  • 17
3
votes
1 answer

Adding custom directories (source and spec) to autotest in a Rails 3 project

I have a Rails 3 app that uses RSpec2 as my testing framework, and I'm able to use autotest to watch my model and spec directories for changes and re-run my spec suite when files change. I'd like to add a directory with some custom classes in it…
Ganesh Shankar
  • 4,826
  • 8
  • 43
  • 56
3
votes
1 answer

ZenTest autotest not running tests

I'm running into the exact same problem as was posted at: ZenTest autotest not running tests. However, nothing on that article is helping me to solve the problem. I have ZenTest and autotest-rails both installed, and yet when I run autotest from the…
Andrew H
  • 517
  • 6
  • 14
3
votes
2 answers

invalid option: --autospec

/usr/local/bin/ruby -rrubygems -e "require 'redgreen'" /usr/local/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec --autospec -O spec/spec.opts invalid option: --autospec Test::Unit automatic runner. Usage: -e [options] [-- untouched…
Ram on Rails
  • 1,299
  • 11
  • 25
3
votes
1 answer

Error after second spec run with rspec and autospec

After installing rspec/ZenTest and running autospec, it runs my specs the first time as expected. After making a change to one of my specs and upon running the second time I get the following results: /usr/bin/ruby1.8…
Sean Chambers
  • 8,572
  • 7
  • 41
  • 55
3
votes
5 answers

ZenTest autotest not running tests

I've had problems with autotest before which I resolved by downgrading from ZenTest 4.1.4 to 4.1.3. $ ruby -v ruby 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0] $ rails -v Rails 2.3.4 Currently I'm finding that on my Mac OS 10.6.1 Snow…
Ethan
  • 57,819
  • 63
  • 187
  • 237
3
votes
2 answers

ZenTest errors preventing autotest from running

I've previously added ZenTest to my gemfile to get autotest to run. On this occasion I get the following error four times over: saasbook@saasbook:~/Documents/github/LocalSupport$ bundle exec autotest Invalid gemspec in…
Sam Joseph
  • 4,584
  • 4
  • 31
  • 47
2
votes
3 answers

I cant get rspec autotest to working? (Ruby, no rails)

I have a basic ruby project :- $ tree . ├── Gemfile ├── lib │   ├── checkout.rb │   └── item.rb ├── README.md └── test ├── checkout_spec.rb └── item_spec.rb Which can run the rspec tests :- $ rspec test/*_spec.rb .... Finished in 0.18797…
Ian Vaughan
  • 20,211
  • 13
  • 59
  • 79
2
votes
1 answer

Shoulda, Rails Tests , and Autotest

I'm trying to model my tests after the great work that the Thougtbot guys have done. They seem to use the test framework built into Rails Shoulda. Great. I have been hearing a lot about Autotest - that its magical-ness should make things easier....…
Bill
  • 1,563
  • 1
  • 15
  • 28
1 2
3
18 19