Sha256: babf367e2e78b0bb60a04821512d3fa261847b2df08c90f1c690d1f285c3de32
Contents?: true
Size: 1011 Bytes
Versions: 6
Compression:
Stored size: 1011 Bytes
Contents
When(/^I run rubycritic (.*)$/) do |args| rubycritic(args) end Then(/^the exit status indicates an error$/) do expect(last_command_started).to have_exit_status(Rubycritic::Command::StatusReporter::SCORE_BELOW_MINIMUM) end Then(/^the exit status indicates a success$/) do expect(last_command_started).to have_exit_status(Rubycritic::Command::StatusReporter::SUCCESS) end Then(/^it reports:$/) do |report| expect(last_command_started).to have_output_on_stdout(report.gsub('\n', "\n")) end Then(/^there is no output on stdout$/) do expect(last_command_started).to have_output_on_stdout('') end Then(/^it reports the current version$/) do expect(last_command_started).to have_output("RubyCritic #{Rubycritic::VERSION}\n") end Then(/^it reports the error ['"](.*)['"]$/) do |string| expect(last_command_started).to have_output_on_stderr(/#{Regexp.escape(string)}/) end Then(/^it succeeds$/) do expect(last_command_started).to have_exit_status(Rubycritic::Command::StatusReporter::SUCCESS) end
Version data entries
6 entries across 6 versions & 1 rubygems