Enables RSpec/ExampleWording and fixes all issues
Both avoiding 'should' and repiting 'it' on the tests description improves reading them and also makes all descriptions consistent. Read about cop at http://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExampleWording
This commit is contained in:
@@ -5,7 +5,7 @@ describe Poll::BoothAssignment do
|
||||
let(:booth){create(:poll_booth)}
|
||||
let(:booth1){create(:poll_booth)}
|
||||
|
||||
it "should check if there are shifts" do
|
||||
it "checks if there are shifts" do
|
||||
assignment_with_shifts = create(:poll_booth_assignment, poll: poll, booth: booth)
|
||||
assignment_without_shifts = create(:poll_booth_assignment, poll: poll, booth: booth1)
|
||||
officer = create(:poll_officer)
|
||||
@@ -16,7 +16,7 @@ describe Poll::BoothAssignment do
|
||||
expect(assignment_without_shifts.shifts?).to eq(false)
|
||||
end
|
||||
|
||||
it "should delete shifts associated to booth assignments" do
|
||||
it "deletes shifts associated to booth assignments" do
|
||||
assignment = create(:poll_booth_assignment, poll: poll, booth: booth)
|
||||
officer = create(:poll_officer)
|
||||
create(:poll_officer_assignment, officer: officer, booth_assignment: assignment)
|
||||
|
||||
Reference in New Issue
Block a user