demarches-normaliennes/spec/lib/tasks/task_helper_spec.rb

16 lines
349 B
Ruby
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

require 'spec_helper'
describe ProgressReport, lib: true do
context 'when the count pass above 100%' do
let(:total) { 2 }
subject(:progress) { ProgressReport.new(total) }
it 'doesnt raise errors' do
expect do
(total + 2).times { progress.inc }
progress.finish
end.not_to raise_error
end
end
end