Sha256: f0e9705cc2480a7a6f8fd40a52bfc8204d15bb3c2fa9da5fabeb055e6a9f75e5

Contents?: true

Size: 571 Bytes

Versions: 43

Compression:

Stored size: 571 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + "/../../../example_helper")

describe Micronaut::Matchers, '#wrap_expectation' do

  def stub_matcher
    @_stub_matcher ||= simple_matcher do
    end
  end

  def failing_matcher
    @_failing_matcher ||= simple_matcher do
      1.should == 2
    end
  end

  it "should return true if there is no error" do
    wrap_expectation stub_matcher do
    end.should be_true
  end

  it "should return false if there is an error" do
    wrap_expectation failing_matcher do
      raise "error"
    end.should be_false
  end

end

Version data entries

43 entries across 43 versions & 3 rubygems

Version Path
spicycode-micronaut-0.1.8.2 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.1.8.3 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.1.8.5 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.1.9.0 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.0.0 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.0 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.1 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.2 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.3 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.4 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.5 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.1.6 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.10 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.2 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.3 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.4 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.5 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.7 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.8 examples/lib/micronaut/expectations/wrap_expectation_example.rb
spicycode-micronaut-0.2.9 examples/lib/micronaut/expectations/wrap_expectation_example.rb