Sha256: 1a854c1bcb2a07e4fac4fe833a30fe3652822c1849d7fac2132c8997b2974ff8

Contents?: true

Size: 611 Bytes

Versions: 20

Compression:

Stored size: 611 Bytes

Contents

require 'spec_helper'

describe Riddle do
  describe '.version_warning' do
    before :each do
      @existing_version = Riddle.loaded_version
    end
    
    after :each do
      Riddle.loaded_version = @existing_version
    end
    
    it "should do nothing if there is a Sphinx version loaded" do
      STDERR.should_not_receive(:puts)
      
      Riddle.loaded_version = '0.9.8'
      Riddle.version_warning
    end
    
    it "should output a warning if no version is loaded" do
      STDERR.should_receive(:puts)
      
      Riddle.loaded_version = nil
      Riddle.version_warning
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
riddle-2.1.0 spec/riddle_spec.rb
riddle-2.0.0 spec/riddle_spec.rb
riddle-1.5.12 spec/riddle_spec.rb
riddle-1.5.11 spec/riddle_spec.rb
riddle-1.5.10 spec/riddle_spec.rb
riddle-1.5.9 spec/riddle_spec.rb
riddle-1.5.8 spec/riddle_spec.rb
riddle-1.5.7 spec/riddle_spec.rb
riddle-1.5.6 spec/riddle_spec.rb
riddle-1.5.5 spec/riddle_spec.rb
riddle-1.5.4 spec/riddle_spec.rb
riddle-1.5.3 spec/riddle_spec.rb
riddle-1.5.2 spec/riddle_spec.rb
riddle-1.5.1 spec/riddle_spec.rb
riddle-1.5.0 spec/riddle_spec.rb
riddle-1.4.0 spec/riddle_spec.rb
riddle-1.3.3 spec/riddle_spec.rb
riddle-1.3.2 spec/riddle_spec.rb
riddle-1.3.1 spec/riddle_spec.rb
riddle-1.3.0 spec/riddle_spec.rb