Error Loading Autotest Style Autotest Rails
Sign in Pricing Blog Support Search GitHub This repository Watch 2 Star 119 Fork 68 grosser/autotest forked from seattlerb/zentest Code Issues 3 Pull requests 0 Projects 0 Pulse Graphs New issue autotest couldn't see the rspec2 #6 Closed petRUShka opened this Issue May 8, 2010 · 13 comments Projects None yet Labels None yet Milestone No milestone Assignees No one assigned 2 participants petRUShka commented May 8, 2010 I can't force autotest to use rspec2 tests instead of test/unit. # autotest
loading autotest/cucumber_rails
style: CucumberRails
�[f/usr/bin/ruby-svn -I.:lib:test -rubygems -e "['test/unit', 'test/unit/helpers/companies_helper_test.rb', 'test/unit/user_test.rb', 'test/unit/company_test.rb', 'test/functional/companies_controller_test.rb'].each { |f| require f }" | /usr/lib/ruby/gems/svn/gems/autotest-4.2.9/bin/unit_diff -u But rspec spec/ works fine. And autotest/discover.rb have rspec2 line: # cat autotest/discover.rb
Autotest.add_discovery { "rails" }
Autotest.add_discovery { "rspec2" }
Arch Linux x86_64 ruby 1.9.3dev (2010-05-08 trunk 27674) x86_64-linux Rails 3.0.0.beta.3 # gem-svn list | grep rspec
rspec (2.0.0.beta.8)
rspec-core (2.0.0.beta.8)
rspec-expectations (2.0.0.beta.8)
rspec-mocks (2.0.0.beta.8)
rspec-rails (2.0.0.beta.8)
gem-svn list | grep autotest
autotest (4.2.9)autotest-growl (0.2.4)
autotest-rails-pure (4.1.0)
Gemfile:
source 'http://rubygems.org'
gem 'rails', '3.0.0.beta3'
gem 'devise', '1.1.rc1'
gem 'mysql'
group :test do
gem 'database_cleaner'
gem 'rspec-rails', '>=2.0.0.beta.8'
gem 'rspec', '>=2.0.0.beta.8'
gem 'test-unit'
gem 'cucumber', '0.7.2'
gem 'cucumber-rails', '0.3.1'#, :git => 'git://github.com/asl
Autotest Mark Pittillo (markcp) on 2010-04-15 17:40 Trying to set up a Rails 3 project with RSpec and Autotest. I followed these steps exactly: http://gist.github.com/365816 But when I start up autotest, I get: $ autotest loading autotest/rails style: Rails instead of: $ autotest loading autotest/rails_rspec2 style: RailsRspec2 And autotest doesn't seem to do anything. Any idea what's happening? I'm using Ruby 1.9.2-head in rvm. Relevant gems: autotest (4.2.9) autotest-rails (4.1.0) rspec (2.0.0.beta.6) https://github.com/grosser/autotest/issues/6 rspec-core (2.0.0.beta.6) rspec-expectations (2.0.0.beta.6) rspec-mocks (2.0.0.beta.6) rspec-rails (2.0.0.beta.6) ZenTest (4.3.1) Thanks a lot for any help. Mark Report post Edit Move Delete topic Reply with quote Re: Rails 3, Rspec 2, Autotest Tim Riendeau (Guest) on 2010-04-17 17:05 I am having similar issue getting this working. I am running rails3.beta3 with ruby 1.8.7. I followed http://gist.github.com/365816 https://www.ruby-forum.com/topic/208049 and I get the following: loading autotest/rails_rspec2 Autotest style autotest/rails_rspec2 doesn't seem to exist. Aborting. I uninstalled and reinstalled the ZenTest & autotest gems with no luck. The same thing occurs in other rails3 apps. Any help would be much appreciated --Tim Report post Edit Delete Reply with quote Re: Rails 3, Rspec 2, Autotest David Chelimsky (Guest) on 2010-04-17 17:21 On Apr 17, 2010, at 9:42 AM, Tim Riendeau wrote: > I am having similar issue getting this working. I am running rails3.beta3 with ruby 1.8.7. I followed http://gist.github.com/365816 and I get the following: > > loading autotest/rails_rspec2 > Autotest style autotest/rails_rspec2 doesn't seem to exist. Aborting. > > I uninstalled and reinstalled the ZenTest & autotest gems with no luck. The same thing occurs in other rails3 apps. > > Any help would be much appreciated I just modified the gist slightly. It looks like rubygems won't find rspec-rails-2.0.0.beta.7 if we ask for ">= 2.0.0.beta". Anyhow, if I follow the setup in ht
following the gist. Here is my > error, in case the extra data point helps: > > $ autotest > loading autotest/rails_rspec_rspec2 > Error loading Autotest style autotest/rails_rspec_rspec2 (no such file > to load https://www.mail-archive.com/rspec-users@rubyforge.org/msg15220.html -- autotest/rails_rspec_rspec2). Aborting. > > Note the extra "rspec" in the path that it's trying to load. That's because autotest looks in the gem paths and the load path for any files named autotest/discover.rb. http://railscasts.com/episodes/264-guard?view=comments It's finding the one in the rspec-1.3.0 gem, which adds 'rspec', and the one in your app, which is probably adding 'rspec2'. Try adding a file to your app named autotest/rails_rspec_rspec2.rb and require 'autotest/rails_rspec2' error loading in that file. Let us know if that works. > > Here is some more info about my environment: > > wo...@beidleheimer ~/src/git/example $ gem list rspec > > *** LOCAL GEMS *** > > rspec (2.0.0.beta.8, 1.3.0, 1.2.9, 1.2.8, 1.2.6, 1.2.2, 1.2.0, 1.1.9, > 1.1.3, 1.1.0) > rspec-core (2.0.0.beta.8) > rspec-expectations (2.0.0.beta.8) > rspec-mocks (2.0.0.beta.8) > rspec-rails (1.3.2, 1.2.9, 1.2.7.1, 1.2.6, 1.2.2, 1.2.0, 1.1.9) > wo...@beidleheimer ~/src/git/example $ error loading autotest gem list rails > > *** LOCAL GEMS *** > > rails (3.0.0.beta3, 2.3.5, 2.3.4, 2.3.3, 2.3.2, 2.2.2, 2.1.2, 2.1.1, > 2.1.0, 2.0.4, 2.0.2, 2.0.1, 1.2.3) > wo...@beidleheimer ~/src/git/example $ ruby --version > ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-darwin10] > > On Apr 17, 10:42 am, Tim Riendeau
Guard May 02, 2011 | 8 minutes | Testing, Tools Guard watches files and runs a command after a file is modified. This allows you to automatically run tests in the background, restart your development server, reload the browser, and more. Click to Play Video ▶ Tweet Download: source codeProject Files in Zip (260 KB)mp4Full Size H.264 Video (17 MB)m4vSmaller H.264 Video (10.5 MB)webmFull Size VP8 Video (24.8 MB)ogvFull Size Theora Video (23.6 MB) Show NotesASCIIcast30 CommentsSimilar EpisodesNext Episode >< Previous Episode Ciur Eugen over 5 years ago Awesome screencast. Thank you! Ryan, how did you enabled colored output in guard (failure in red, passes in green); is that guard specific? Aaron Cruz over 5 years ago I was just this week looking for a solution to use with sprockets to automatically combine my javascript. Thanks for nudging me toward guard! Rick DeNatale over 5 years ago Nice RailsCast, as usual. Ryan, did you know about the -c option when starting guard? It auto clears the screen using the clear shell command before each guard runs after detecting a change. Joshua Muheim over 4 years ago Very useful, just been looking for this! Thank you. Andy L over 5 years ago Does anyone know of a way to 'hyperlink' from an rspec failure message to the correct file & line number in vim ?? devwout over 5 years ago Putting a RUBY_PLATFORM condition in the Gemfile is not a good idea. When installing an application bundle on the production server (different platform) with the --deployment or --frozen option, bundler will complain that the Gemfile does not match the Gemfile.lock. However, I don't see an alternative right now... matt-hwy1 over 4 years ago +1. Yes this breaks deployment from Mac to a non-Mac platform. I just leave off the OS-specific line, since I'm deploying to production, and the gem is only used for dev/test on my Mac. Lucas Uyezu over 3 years ago The official docs says to require all 3 gems (Linux, OS X and Windows). The gem will know which one to use. ruby group :development do gem 'rb-inotify', :require => false gem 'rb-fsevent', :require => false gem 'rb-fchange', :require => false end Karl Smith over 5 years ago Pair guard with spork and guard-spork. Now you have even faster tests! edited by moderator ( links ) Kieran P over 5 years ago Lol, ironic that Guard can't reload it's own config. Thibaud Guillaume-Gentil over 5 years ago https://github.com/guard/guard-ego :) ranska over 5 years ago Than