Permalink
Browse files

Supply -u root to mysqladmin for create and drop database calls

  • Loading branch information...
1 parent 3fb7618 commit a2795fff0e368af63c21b9929956f2be436a8ba1 @lukemelia lukemelia committed Apr 26, 2010
Showing with 3 additions and 3 deletions.
  1. +1 −1 features/mysql.feature
  2. +2 −2 lib/testjour/mysql.rb
@@ -7,7 +7,7 @@ Feature: MySQL databases
Scenario: Create MySQL databases
When I run `testjour --create-mysql-db mysql_db.feature`
Then it should pass with "1 steps passed"
- And testjour.log should include "mysqladmin create testjour_runner_"
+ And testjour.log should include "mysqladmin -u root create testjour_runner_"
Scenario: Don't create MySQL databases by default
When I run `testjour mysql_db.feature`
@@ -9,11 +9,11 @@ def initialize(runner_database_name = nil)
end
def create_database
- run "/usr/local/mysql/bin/mysqladmin create #{runner_database_name}"
+ run "/usr/local/mysql/bin/mysqladmin -u root create #{runner_database_name}"
end
def drop_database
- run "/usr/local/mysql/bin/mysqladmin -f drop #{runner_database_name}"
+ run "/usr/local/mysql/bin/mysqladmin -u root -f drop #{runner_database_name}"
end
def load_schema

0 comments on commit a2795ff

Please sign in to comment.