Sha256: 7292ea7f10c98d002570d77fc808f495fc242a1ad54a890557c549e57992eeb2

Contents?: true

Size: 1.42 KB

Versions: 20

Compression:

Stored size: 1.42 KB

Contents

test "output of successful run" do
  expected = "•"

  out = %x{./bin/cutest test/fixtures/success.rb}

  assert out[expected]
end

test "exit code of successful run" do
  %x{./bin/cutest test/fixtures/success.rb}
  assert_equal 0, $?.to_i
end

test "output of failed run" do
  expected = "failed assertion"

  out = %x{./bin/cutest test/fixtures/failure.rb}

  assert out[expected]
end

test "output of failed run" do
  expected = "RuntimeError"

  out = %x{./bin/cutest test/fixtures/exception.rb}

  assert out[expected]
end

test "exit code of failed run" do
  %x{./bin/cutest test/fixtures/failure.rb}

  assert $?.to_i != 0
end

test "output of custom assertion" do
  expected = "Cutest::AssertionFailed"

  out = %x{./bin/cutest test/fixtures/fail_custom_assertion.rb}

  assert out[expected]
end

test "output of failure in nested file" do
  expected = "Cutest::AssertionFailed"

  out = %x{./bin/cutest test/fixtures/failure_in_loaded_file.rb}

  assert out[expected]
end

test "output of failure outside block" do
  expected = "Cutest::AssertionFailed"

  out = %x{./bin/cutest test/fixtures/outside_block.rb}

  assert out[expected]
end

test "only runs given scope name" do
  out = %x{./bin/cutest test/fixtures/only_run_given_scope_name.rb -s scope}

  assert out =~ /This is raised/
end

test "runs by given scope and test names" do
  %x{./bin/cutest test/fixtures/only_run_given_scope_name.rb -s scope -t test}

  assert_equal 0, $?.to_i
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
cutest-cj-1.7.1 test/run.rb
cutest-cj-1.7.0 test/run.rb
cutest-cj-1.6.4 test/run.rb
cutest-cj-1.6.3 test/run.rb
cutest-cj-1.6.2 test/run.rb
cutest-cj-1.6.1 test/run.rb
cutest-cj-1.6.0 test/run.rb
cutest-cj-1.5.1 test/run.rb
cutest-cj-1.5.0 test/run.rb
cutest-cj-1.4.0 test/run.rb
cutest-cj-1.3.9 test/run.rb
cutest-cj-1.3.8 test/run.rb
cutest-cj-1.3.7 test/run.rb
cutest-cj-1.3.6 test/run.rb
cutest-cj-1.3.5 test/run.rb
cutest-cj-1.3.4 test/run.rb
cutest-cj-1.3.3 test/run.rb
cutest-cj-1.3.2 test/run.rb
cutest-cj-1.3.1 test/run.rb
cutest-cj-1.3.0 test/run.rb