spec/rubocop/cop/rspec/described_class_spec.rb in rubocop-rspec-1.34.0 vs spec/rubocop/cop/rspec/described_class_spec.rb in rubocop-rspec-1.34.1

- old
+ new

@@ -253,9 +253,21 @@ expect_no_offenses(<<-RUBY) describe MyClass do end RUBY end + + it 'ignores if a local variable is part of the namespace' do + expect_no_offenses(<<-RUBY) + describe Broken do + [Foo, Bar].each do |klass| + describe klass::Baz.name do + it { } + end + end + end + RUBY + end end context 'when EnforcedStyle is :explicit' do let(:cop_config) { { 'EnforcedStyle' => :explicit } }