On Thu, Nov 11, 2010 at 9:49 AM, Dean Richardson <li...@ruby-forum.com> wrote:
> David:
>
> Thanks for your help. I've followed the set-up instructions in the "BDD
> in Rails" chapter successfully up to the "rake db:test:prepare" step. At
> that point, I get the following error:
>
> rake aborted!
> no such file to load -- sqlite3
>
> I've attached a document containing my "gem list" output showing the
> presence of the sqlite3-ruby gem and other associated dependencies. The
> document also gives the content of my database.yml file for reference.
> I'm using mysql for my development and production databases.
>
> When I try to switch my test database to mysql too, by editing the
> "test:" section of database.yml, I get the following error:
>
> rake aborted!
> Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
>
> Both of these errors are widely-discussed on message boards, stack
> overflow, etc., but none of the fixes I've found so far there seem to
> help.
>
> Any suggestions for how to make either test database approach (sqlite3
> or mysql) work would be greatly appreciated.
>

Hello,

To better understand what is going on with sqlite3 adapter will
require more details.

As for the mysql error, in your database.yml, just copy your
configuration from development section and rename the database to your
test one.

Ensure the socket line is not there, as is the one affecting your
mysql execution.

HTH,
-- 
Luis Lavena
AREA 17
-
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to