File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
spec/database_cleaner/active_record Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 106106 it "specifies cascade when truncating" do
107107 User . create! ( { name : 1 } )
108108
109- expect ( strategy . send ( :connection ) ) . to receive ( :truncate_tables ) . with ( [ 'users' , 'agents' ] , { truncate_option : :cascade } )
109+ expect ( strategy . send ( :connection ) ) . to receive ( :truncate_tables ) . with ( [ 'users' , 'agents' ] . sort , { truncate_option : :cascade } )
110110 strategy . clean
111111 end
112112 end
117117 it "specifies restrict when truncating" do
118118 User . create!
119119
120- expect ( strategy . send ( :connection ) ) . to receive ( :truncate_tables ) . with ( [ 'users' , 'agents' ] , { truncate_option : :restrict } )
120+ expect ( strategy . send ( :connection ) ) . to receive ( :truncate_tables ) . with ( [ 'users' , 'agents' ] . sort , { truncate_option : :restrict } )
121121 strategy . clean
122122 end
123123 end
You can’t perform that action at this time.
0 commit comments