Early Stage Error - Testing with RSPec

Hello RoR-ists. First, thanks for your help.

As a noob, I’ve been happily chugging along this well-known tutorial:

http://ruby.railstutorial.org/chapters/static-pages#top

and I’m caught in a section where I enter

rspec spec/

where I receive 2 errors. The 2 errors are in the format of

  1. PagesController GET ‘home’ should be successful
    Failure/Error: Unable to find matching line from backtrace
    Mysql2::Error:
    Unknown database ‘xyz.rb’

where “home” is the name of the action/page. The xyz.rb is the arbitrary
database name I have listed under the test section in database.yml. I
have already raked the database.

I’m pretty sure my problem has to do with how I’m not going with the
sqlite3 in the tutorial but instead with mysql2. The resources I have
managed to find only give guidance on what to input for the development
section in database.yml, but not for the rest of the sections like
“test”. So, my question is, what exactly does this error mean, how to
fix it, and how should I configure my database.yml file? I tried
entering a file I see in my db folder like schema.rb, but this renders
the same error.

Thank you very much for your help.

hmmm no one knows?

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs