Sha256: f3007b7e311833b1b47b84acaf3400950fa562e25b8d2b0146c38ece69519aa4

Contents?: true

Size: 975 Bytes

Versions: 13

Compression:

Stored size: 975 Bytes

Contents

Feature: Test::Unit integration

  RSpec-expectations is a stand-alone gem that can be used without
  the rest of RSpec.  It can easily be used with another test
  framework such as Test::Unit if you like RSpec's should/should_not
  syntax but prefer the test organization of another framework.

  Scenario: Basic Test::Unit usage
    Given a file named "rspec_expectations_test.rb" with:
      """
      require 'test/unit'
      require 'rspec/expectations'

      class RSpecExpectationsTest < Test::Unit::TestCase
        def test_passing_expectation
          x = 1 + 3
          x.should == 4
        end

        def test_failing_expectation
          array = [1, 2]
          array.should be_empty
        end
      end
      """
     When I run "ruby rspec_expectations_test.rb"
     Then the output should contain "2 tests"
      And the output should contain "1 failure" or "1 error"
      And the output should contain "expected empty? to return true, got false"

Version data entries

13 entries across 13 versions & 2 rubygems

Version Path
gemrage-1.0.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.4.1 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.4.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.3.2 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.3.1 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.3.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.2.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.1.2 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.1.1 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.1.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
gemrage-0.0.0 vendor/ruby/1.8/gems/rspec-expectations-2.0.0/features/test_frameworks/test_unit.feature
rspec-expectations-2.0.0 features/test_frameworks/test_unit.feature
rspec-expectations-2.0.0.rc features/test_frameworks/test_unit.feature