spec/concerned_spec.rb in concerned-0.1.2 vs spec/concerned_spec.rb in concerned-0.1.3

- old
+ new

@@ -13,9 +13,27 @@ shared_concerns :associations include_shared_concerns :caching include_concerns :validations end +class FixtureUserNoMeta + concerned_with :scopes, :validations + shared_concerns :associations + include_shared_concerns :caching + include_concerns :validations +end + + +describe "Concerned" do + describe "no meta" do + it 'should not have meta info' do + FixtureUserNoMeta.should_not respond_to(:my_concerns) + FixtureUserNoMeta.should_not respond_to(:my_shared_concerns) + FixtureUserNoMeta.should_not respond_to(:all_my_concerns) + end + end +end + describe "Concerned" do describe "#concerned_with" do it 'should require files from #{name.underscore}/#{concern}' do [:scopes, :validations].each do |concern| FixtureUser.new.should respond_to("method_from_#{concern}_concern")