test/test_mysql2.rb in upsert-0.0.1 vs test/test_mysql2.rb in upsert-0.1.0
- old
+ new
@@ -4,11 +4,11 @@
system %{ mysql -u root -ppassword -e "DROP DATABASE IF EXISTS test_upsert; CREATE DATABASE test_upsert CHARSET utf8" }
ActiveRecord::Base.establish_connection :adapter => 'mysql2', :username => 'root', :password => 'password', :database => 'test_upsert'
describe "upserting on mysql2" do
before do
- ActiveRecord::Base.connection.drop_table Pet.table_name rescue nil
+ ActiveRecord::Base.connection.drop_table(Pet.table_name) rescue nil
Pet.auto_upgrade!
@opened_connections = []
@connection = new_connection
end
after do
@@ -21,8 +21,17 @@
end
def connection
@connection
end
- it_behaves_like :database
+ it_also 'is a database with an upsert trick'
+ it_also 'is just as correct as other ways'
+
+ it_also 'can be speeded up with upserting'
+
+ it_also 'supports binary upserts'
+
+ it_also "supports multibyte"
+
+ it_also "doesn't mess with timezones"
end