Correctly clear theme double

pull/4945/head
Oliver Günther 8 years ago
parent 320612b65b
commit 64d14634ff
No known key found for this signature in database
GPG Key ID: 88872239EB414F99
  1. 7
      spec/lib/open_project/themes/theme_finder_spec.rb

@ -31,9 +31,9 @@ require 'spec_helper'
module OpenProject
module Themes
describe ThemeFinder do
before do ThemeFinder.clear_themes end
# clear theme state after we are finished so that we do not disturb following tests
after(:all) do ThemeFinder.clear_themes end
after(:each) do
ThemeFinder.clear_themes
end
describe '.themes' do
it 'returns all instances of descendants of themes' do
@ -78,6 +78,7 @@ module OpenProject
theme = double # do not invoke inherited callback
ThemeFinder.register_theme(theme)
expect(ThemeFinder.themes).to include theme
ThemeFinder.forget_theme(theme)
end
it 'clears the cache successfully' do

Loading…
Cancel
Save