Skip to content

Commit 4b6fb17

Browse files
authored
Merge pull request rails#37505 from dr-itz/fix/6-0-tests
activerecord: fix some test failers caused by recent backports
2 parents 0dd2404 + 2e17477 commit 4b6fb17

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

activerecord/test/cases/arel/attributes_test.rb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,40 +27,40 @@ module Arel
2727
describe "for" do
2828
it "deals with unknown column types" do
2929
column = Struct.new(:type).new :crazy
30-
Attributes.for(column).must_equal Attributes::Undefined
30+
_(Attributes.for(column)).must_equal Attributes::Undefined
3131
end
3232

3333
it "returns the correct constant for strings" do
3434
[:string, :text, :binary].each do |type|
3535
column = Struct.new(:type).new type
36-
Attributes.for(column).must_equal Attributes::String
36+
_(Attributes.for(column)).must_equal Attributes::String
3737
end
3838
end
3939

4040
it "returns the correct constant for ints" do
4141
column = Struct.new(:type).new :integer
42-
Attributes.for(column).must_equal Attributes::Integer
42+
_(Attributes.for(column)).must_equal Attributes::Integer
4343
end
4444

4545
it "returns the correct constant for floats" do
4646
column = Struct.new(:type).new :float
47-
Attributes.for(column).must_equal Attributes::Float
47+
_(Attributes.for(column)).must_equal Attributes::Float
4848
end
4949

5050
it "returns the correct constant for decimals" do
5151
column = Struct.new(:type).new :decimal
52-
Attributes.for(column).must_equal Attributes::Decimal
52+
_(Attributes.for(column)).must_equal Attributes::Decimal
5353
end
5454

5555
it "returns the correct constant for boolean" do
5656
column = Struct.new(:type).new :boolean
57-
Attributes.for(column).must_equal Attributes::Boolean
57+
_(Attributes.for(column)).must_equal Attributes::Boolean
5858
end
5959

6060
it "returns the correct constant for time" do
6161
[:date, :datetime, :timestamp, :time].each do |type|
6262
column = Struct.new(:type).new type
63-
Attributes.for(column).must_equal Attributes::Time
63+
_(Attributes.for(column)).must_equal Attributes::Time
6464
end
6565
end
6666
end

activerecord/test/cases/test_case.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ def clear_log; self.log = []; self.log_all = []; end
113113
# ignored SQL, or better yet, use a different notification for the queries
114114
# instead examining the SQL content.
115115
oracle_ignored = [/^select .*nextval/i, /^SAVEPOINT/, /^ROLLBACK TO/, /^\s*select .* from all_triggers/im, /^\s*select .* from all_constraints/im, /^\s*select .* from all_tab_cols/im, /^\s*select .* from all_sequences/im]
116-
mysql_ignored = [/^SHOW FULL TABLES/i, /^SHOW FULL FIELDS/, /^SHOW CREATE TABLE /i, /^SHOW VARIABLES /, /^\s*SELECT (?:column_name|table_name)\b.*\bFROM information_schema\.(?:key_column_usage|tables)\b/im]
116+
mysql_ignored = [/^SHOW FULL TABLES/i, /^SHOW FULL FIELDS/, /^SHOW CREATE TABLE /i, /^SHOW VARIABLES /, /^\s*SELECT (?:column_name|table_name)\b.*\bFROM information_schema\.(?:key_column_usage|tables|statistics)\b/im]
117117
postgresql_ignored = [/^\s*select\b.*\bfrom\b.*pg_namespace\b/im, /^\s*select tablename\b.*from pg_tables\b/im, /^\s*select\b.*\battname\b.*\bfrom\b.*\bpg_attribute\b/im, /^SHOW search_path/i, /^\s*SELECT\b.*::regtype::oid\b/im]
118118
sqlite3_ignored = [/^\s*SELECT name\b.*\bFROM sqlite_master/im, /^\s*SELECT sql\b.*\bFROM sqlite_master/im]
119119

0 commit comments

Comments
 (0)