I am doing a Ruby on Rails Tutorial. In the first three chapters, he uses SQLite, but later he suggests using PostgreSQL for development to simplify the deployment of Heroku. After editing my database.yml and Gemfile to use pg instead of sqlite3, it seems to work, except when using Rake to run the test. It throws an AdapterNotSpecified error.
C:/Ruby/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/activerecord-4.0.0/lib/active_record/ connection_adapters/connection_specification.rb:52:in resolve_hash_connection': database configuration does not specify adapter (ActiveRecord::AdapterNotSpecif ied)
and etc.
An adapter is specified in the .yml database, for example:
development: adapter: postgresql host: localhost username: nekkoru password: derpderp database: development encoding: UTF8
What's happening? I am on Windows 7 x64, Ruby 1.9.3, Rails 4.0.0, PostgreSQL 9.3.0.1.
source share