upgrade pat3

This commit is contained in:
2013-12-21 16:46:07 +01:00
parent b4c4a15e60
commit c6f790eccd
12 changed files with 124 additions and 80 deletions
+11
View File
@@ -45,4 +45,15 @@ describe :section do
end
end
describe '#tables_with_active_list_id' do
it 'caches the result for tables call' do
section = create :section
table = create :table, section: section
section = Section.find section.id # ensure a totally clean object
section.tables_with_active_list_id
Table.database.stub(:view).and_raise 'No view should be called here'
expect{ section.tables }.not_to raise_error
end
end
end