1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

ignore selects from data dictionary views when running tests on Oracle

This commit is contained in:
Raimonds Simanovskis 2010-03-07 16:46:59 +02:00
parent 5fcaf91761
commit c6d6b50166

View file

@ -53,7 +53,7 @@ Course.establish_connection 'arunit2'
# for assert_queries test helper
ActiveRecord::Base.connection.class.class_eval do
IGNORED_SELECT_SQL = [/^select .*nextval/i, /^SAVEPOINT/, /^ROLLBACK TO SAVEPOINT/, /^RELEASE SAVEPOINT/, /^\s*select .* from (all_tab_columns|all_triggers)/im]
IGNORED_SELECT_SQL = [/^select .*nextval/i, /^SAVEPOINT/, /^ROLLBACK TO/, /^\s*select .* from ((all|user)_tab_columns|(all|user)_triggers|(all|user)_constraints)/im]
def select_with_query_record(sql, name = nil, return_column_names = false)
$queries_executed ||= []