Sha256: af094e883be0c913ddc679ff1d4acf4730fc7a50e52de6e5a93678cea869d0de

Contents?: true

Size: 1 KB

Versions: 11

Compression:

Stored size: 1 KB

Contents

require 'spec_helper'

describe Jasmine::Results do
  it "should be able to return suites" do
    suites = {:some => 'suite'}
    Jasmine::Results.new({}, suites, {}).suites.should == suites
  end

  it "should return a result for a particular spec id" do
    result1 = {:some => 'result'}
    result2 = {:some => 'other result'}
    raw_results = {'1' => result1, '2' => result2 }
    results = Jasmine::Results.new(raw_results, {}, {})
    results.for_spec_id('1').should == result1
    results.for_spec_id('2').should == result2
  end

  it "should return an example location for a particular string" do
    example_location1 = {:some => 'spec location'}
    example_location2 = {:some => 'other spec location'}
    example_locations = {'foo bar' => example_location1, 'baz quux' => example_location2 }
    results = Jasmine::Results.new({}, {}, example_locations)
    results.example_location_for('foo bar').should == example_location1
    results.example_location_for('baz quux').should == example_location2
  end
end

Version data entries

11 entries across 11 versions & 3 rubygems

Version Path
jasmine-multi_json-1.3.2.1 spec/results_spec.rb
jasmine-1.3.2 spec/results_spec.rb
jasmine-multi_json-1.3.1.1 spec/results_spec.rb
jasmine-1.3.1 spec/results_spec.rb
jasmine-1.3.0 spec/results_spec.rb
rally-jasmine-1.2.0.4 spec/results_spec.rb
rally-jasmine-1.2.0.3 spec/results_spec.rb
rally-jasmine-1.2.0.2 spec/results_spec.rb
rally-jasmine-1.2.0.1 spec/results_spec.rb
rally-jasmine-1.2.0 spec/results_spec.rb
jasmine-1.2.1 spec/results_spec.rb