Skip to content

Commit d5a47ed

Browse files
committed
re-org librarian spec fixtures
1 parent 07a6247 commit d5a47ed

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed
File renamed without changes.

spec/puppet-check/ruby_parser_spec.rb

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -79,30 +79,30 @@
7979

8080
context '.librarian' do
8181
it 'puts a bad syntax librarian Puppet file in the error files hash' do
82-
RubyParser.librarian(["#{fixtures_dir}librarian_syntax/Puppetfile"], false, [])
83-
expect(PuppetCheck.files[:errors].keys).to eql(["#{fixtures_dir}librarian_syntax/Puppetfile"])
84-
expect(PuppetCheck.files[:errors]["#{fixtures_dir}librarian_syntax/Puppetfile"].join("\n")).to match(/^.*syntax error/)
82+
RubyParser.librarian(["#{fixtures_dir}librarian/Puppetfile_syntax"], false, [])
83+
expect(PuppetCheck.files[:errors].keys).to eql(["#{fixtures_dir}librarian/Puppetfile_syntax"])
84+
expect(PuppetCheck.files[:errors]["#{fixtures_dir}librarian/Puppetfile_syntax"].join("\n")).to match(/^.*syntax error/)
8585
expect(PuppetCheck.files[:warnings]).to eql({})
8686
expect(PuppetCheck.files[:clean]).to eql([])
8787
end
8888
it 'puts a bad style librarian Puppet file in the warning files array' do
89-
RubyParser.librarian(["#{fixtures_dir}librarian_style/Puppetfile"], true, [])
89+
RubyParser.librarian(["#{fixtures_dir}librarian/Puppetfile_style"], true, [])
9090
expect(PuppetCheck.files[:errors]).to eql({})
91-
expect(PuppetCheck.files[:warnings].keys).to eql(["#{fixtures_dir}librarian_style/Puppetfile"])
92-
expect(PuppetCheck.files[:warnings]["#{fixtures_dir}librarian_style/Puppetfile"].join("\n")).to match(/Align the arguments.*\n.*Use the new/)
91+
expect(PuppetCheck.files[:warnings].keys).to eql(["#{fixtures_dir}librarian/Puppetfile_style"])
92+
expect(PuppetCheck.files[:warnings]["#{fixtures_dir}librarian/Puppetfile_style"].join("\n")).to match(/Align the arguments.*\n.*Use the new/)
9393
expect(PuppetCheck.files[:clean]).to eql([])
9494
end
9595
it 'puts a bad style librarian Puppet file in the clean files array when rubocop_args ignores its warnings' do
96-
RubyParser.librarian(["#{fixtures_dir}librarian_style/Puppetfile"], true, ['--except', 'Layout/ArgumentAlignment,Style/HashSyntax'])
96+
RubyParser.librarian(["#{fixtures_dir}librarian/Puppetfile_style"], true, ['--except', 'Layout/ArgumentAlignment,Style/HashSyntax'])
9797
expect(PuppetCheck.files[:errors]).to eql({})
9898
expect(PuppetCheck.files[:warnings]).to eql({})
99-
expect(PuppetCheck.files[:clean]).to eql(["#{fixtures_dir}librarian_style/Puppetfile"])
99+
expect(PuppetCheck.files[:clean]).to eql(["#{fixtures_dir}librarian/Puppetfile_style"])
100100
end
101101
it 'puts a good librarian Puppet file in the clean files array' do
102-
RubyParser.librarian(["#{fixtures_dir}librarian_good/Puppetfile"], true, [])
102+
RubyParser.librarian(["#{fixtures_dir}librarian/Puppetfile_good"], true, [])
103103
expect(PuppetCheck.files[:errors]).to eql({})
104104
expect(PuppetCheck.files[:warnings]).to eql({})
105-
expect(PuppetCheck.files[:clean]).to eql(["#{fixtures_dir}librarian_good/Puppetfile"])
105+
expect(PuppetCheck.files[:clean]).to eql(["#{fixtures_dir}librarian/Puppetfile_good"])
106106
end
107107
end
108108
end

0 commit comments

Comments
 (0)