Skip to content

Commit

Permalink
Add a spec for the changelog file format
Browse files Browse the repository at this point in the history
Follow up to rubocop/rubocop#10237.
  • Loading branch information
koic committed Nov 12, 2021
1 parent a1c87de commit 4dd3b9a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions spec/project_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,10 @@
expect(entries).to all(match(/\(\[@\S+\]\[\](?:, \[@\S+\]\[\])*\)$/))
end

it 'has a single line' do
expect(File.foreach(path).count).to eq(1)
end

it 'starts with `new_`, `fix_`, or `change_`' do
expect(File.basename(path)).to(match(/\A(new|fix|change)_.+/))
end
Expand Down

0 comments on commit 4dd3b9a

Please sign in to comment.