LoginSignup
0
0

More than 5 years have passed since last update.

rake test:prepare

Posted at

$ bundle exec rake db:migrate
$ bundle exec rake test:prepare

rake aborted!
Don't know how to build task 'test:prepare'
/Users/takako/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/bin/ruby_executable_hooks:15:in eval'
/Users/takako/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/bin/ruby_executable_hooks:15:in
'
(See full trace by running task with --trace)

'test:prepare'がないみたい

そこで、テスト用のDBを作る
$ rake db:create db:migrate RAILS_ENV=test

db/test.sqlite3 already exists
== 20140725021324 CreateUsers: migrating ======================================
-- create_table(:users)
-> 0.0022s
== 20140725021324 CreateUsers: migrated (0.0024s) =============================

すでにある?泣

$ bundle exec rake db:migrate
$ bundle exec rake test:prepare

rake aborted!
Don't know how to build task 'test:prepare'

$ bundle exec rake db:create:all

db/development.sqlite3 already exists
db/test.sqlite3 already exists

ううん。。

$ bundle exec rspec spec/models/user_spec.rb

No DRb server is running. Running in local process instead ...
....

Finished in 0.05868 seconds
4 examples, 0 failures

Randomized with seed 54796

Run options: --seed 29489

Running:

Finished in 0.003481s, 0.0000 runs/s, 0.0000 assertions/s.

0 runs, 0 assertions, 0 failures, 0 errors, 0 skips

動いた!?
保留

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0