Sha256: 9fe5519624c9c300af08f893a457a4339b5e301271eb47b7f4422041290378c2

Contents?: true

Size: 847 Bytes

Versions: 6

Compression:

Stored size: 847 Bytes

Contents

require 'vatsim_online'
require 'callsign_parser_spec_helper.rb'

describe VatsimTools::CallsignParser do

  target = VatsimTools::CallsignParser

  describe "stations" do
    it "should return an expected result" do
      gem_data_file
      callsign = "WMKK"
      target.new(callsign).stations.first[0].should eq("WMKK_APP")
      target.new(callsign).stations.class.should eq(Array)
    end   
  end

  describe "station_objects" do
    it "should return an array of Station objects" do
      gem_data_file
      callsign = "LO"
      target.new(callsign).station_objects.class.should eq(Array)
      target.new(callsign).station_objects.size.should eq(2)
      target.new(callsign).station_objects.first.class.should eq(VatsimTools::Station)
      target.new(callsign).station_objects.first.callsign.should eq("LOT282")
    end
  end

  
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
vatsim_online-0.9.1 spec/callsign_parser_spec.rb
vatsim_online-0.9 spec/callsign_parser_spec.rb
vatsim_online-0.8.3 spec/callsign_parser_spec.rb
vatsim_online-0.8.2 spec/callsign_parser_spec.rb
vatsim_online-0.8.1 spec/callsign_parser_spec.rb
vatsim_online-0.8 spec/callsign_parser_spec.rb