ierail 0.3.4 → 0.3.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- M2I4ZmZhZmU5MDM4N2Y0YzQyYTIxZDFjMTFmOWYxZDEyMzkyNmQ2Yg==
5
- data.tar.gz: !binary |-
6
- OGZhZTJjMDA5NzQ4NjhhOWVjZGM3NTc3YjgyOTFiZTdhOGVlNGI0ZQ==
7
- !binary "U0hBNTEy":
8
- metadata.gz: !binary |-
9
- ZjQ1NjY0NmVmY2QxMmE2MjcwZmE0ZjIxYjAzMmM4ZTA3NTY1MDI5MGQ4ODlj
10
- MDljZGFkZTcwMTkyMzgzNDVlNjkxYTQ0YTZhMTE3NzQwMTQ4NjViNWE4MWFk
11
- NTQxMDQzMmI1ZDQyYjMwM2M3NDQzNjZhNWJmZDRlMDRjM2ZlY2E=
12
- data.tar.gz: !binary |-
13
- ZDIzZjI2MTA3Y2M1ZThkYzNhOWVkNWQ2YTFjY2VmMjcwNmJlZmJlOTc0M2Zi
14
- NzQwYzY3ZTA2NWFlZWUyZDE5NjY4MmI0ZDAwMmU1ZGQ5MDQ2NmFlNDBiNDVl
15
- ZGRmNTgwNmVmNDE5MDE0NWEwNGYwNDMxYTFiOWIyODUyZDhmOWE=
2
+ SHA1:
3
+ metadata.gz: 8624329e17244b7bebb63b152459c3bf590a3458
4
+ data.tar.gz: 8614aa0c660b016fb50b2f537215268e0a49684f
5
+ SHA512:
6
+ metadata.gz: fbec8afce43b9f6da40921a3dacb4c851e10376810a095a25a3cd3f106dff6afcdedcc01cf01f6768476aa7b408af4965ccca818673bac424946ee5027413d7d
7
+ data.tar.gz: 92f1ff53061f37dd7805b887670dbc6c9dff4da32f0c55223aac514efd332e81d1e3e33babee693fed9a04e1e6169d0b45f3f1fe431995babe7fd9845a377cb0
data/.gitignore CHANGED
@@ -1 +1,2 @@
1
1
  coverage
2
+ .DS_Store
data/.travis.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  language: ruby
2
2
  rvm:
3
+ - 2.1.0
4
+ - 2.0.0
3
5
  - 1.9.3
4
- - 1.9.2
5
- - jruby-19mode
6
- - rbx-19mode
6
+ - jruby
data/Gemfile.lock CHANGED
@@ -1,11 +1,11 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ierail (0.3.3)
5
- json (~> 1.7.7)
6
- nokogiri (~> 1.5.0)
7
- rest-client (~> 1.6.7)
8
- tzinfo (~> 0.3.37)
4
+ ierail (0.3.5)
5
+ json (~> 1.7, >= 1.7.7)
6
+ nokogiri (~> 1.5, >= 1.5.0)
7
+ rest-client (~> 1.6, >= 1.6.7)
8
+ tzinfo (~> 0.3, >= 0.3.37)
9
9
 
10
10
  GEM
11
11
  remote: https://rubygems.org/
@@ -17,10 +17,10 @@ GEM
17
17
  rest-client
18
18
  simplecov (>= 0.7)
19
19
  thor
20
- json (1.7.7)
20
+ json (1.8.1)
21
21
  mime-types (1.23)
22
22
  multi_json (1.7.3)
23
- nokogiri (1.5.9)
23
+ nokogiri (1.5.11)
24
24
  rake (10.0.4)
25
25
  rest-client (1.6.7)
26
26
  mime-types (>= 1.16)
@@ -29,9 +29,10 @@ GEM
29
29
  simplecov-html (~> 0.7.1)
30
30
  simplecov-html (0.7.1)
31
31
  thor (0.18.1)
32
- tzinfo (0.3.37)
32
+ tzinfo (0.3.39)
33
33
 
34
34
  PLATFORMS
35
+ java
35
36
  ruby
36
37
 
37
38
  DEPENDENCIES
data/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  [![Build Status](https://travis-ci.org/oisin/ierail.png?branch=master)](https://travis-ci.org/oisin/ierail)
2
2
  [![Coverage Status](https://coveralls.io/repos/oisin/ierail/badge.png?branch=master)](https://coveralls.io/r/oisin/ierail)
3
+ [![Gem Version](https://badge.fury.io/rb/ierail.png)](http://badge.fury.io/rb/ierail)
3
4
 
4
5
  ## Irish Rail API Ruby Wrapper
5
6
 
@@ -12,57 +13,70 @@ It's a trivial wrapper for the Irish Rail real time (whut?) train times system,
12
13
  ### Grab the IERail gem
13
14
 
14
15
 
15
- `$ gem install ierail`
16
+ ```bash
17
+ $ gem install ierail
18
+ ```
16
19
 
17
- <pre><code>require 'ierail'
20
+ ```ruby
21
+ require 'ierail'
18
22
 
19
23
  ir = IERail.new
20
- </code></pre>
24
+ ```
21
25
 
22
26
  ### Find all Southbound trains serving Clongriffin station
23
27
 
24
- <pre><code>trains = ir.southbound_from('clongriffin')</code></pre>
28
+ ```ruby
29
+ trains = ir.southbound_from('clongriffin')
30
+ ```
25
31
 
26
32
  ### Find all trains serving Clongriffin in the next 30 minutes
27
33
 
28
- <pre><code>trains = ir.station_times('clongriffin', 30)
34
+ ```ruby
35
+ trains = ir.station_times('clongriffin', 30)
29
36
 
30
- trains.each { |t| puts t.inspect }
31
- </code></pre>
37
+ trains.each { |t| p t.inspect }
38
+ ```
32
39
 
33
40
  ### Find all Northbound trains serving Clongriffin before / after a certain time
34
41
 
35
- <pre><code>trains = ir.northbound_from('clongriffin').after('HH:MM')
42
+ ```ruby
43
+ trains = ir.northbound_from('clongriffin').after('HH:MM')
36
44
  trains = ir.northbound_from('clongriffin').before('HH:MM')
37
- </code></pre>
45
+ ```
38
46
 
39
47
  NB: "HH:MM" must be soon, as the API, by default, returns upcoming
40
48
  arrivals
41
49
 
42
50
  ### Find all Southbound trains from Malahide in the next N minutes
43
51
 
44
- <pre><code>trains = ir.southbound_from('malahide').in(N)
45
- </code></pre>
52
+ ```ruby
53
+ trains = ir.southbound_from('malahide').in(N)
54
+ ```
46
55
 
47
56
  ### Find out information for a specific train
48
57
 
49
- <pre><code>trains = ir.station('clongriffin', 60)
58
+ ```ruby
59
+ trains = ir.station('clongriffin', 60)
50
60
 
51
61
  trains.first.last_location # "Arrived Harmonstown"
52
62
 
53
- trains.first.origin # {:name=>"Greystones", :time=>"07:30"}
63
+ trains.first.origin # {:name=>"Greystones", :time=>2013-05-13 22:10:00 +0100}
54
64
 
55
- trains.first.destination # {:name=>"Malahide", :time=>"08:49"}
65
+ trains.first.destination # {:name=>"Malahide", :time=>2013-05-13 22:10:00 +0100}
56
66
 
57
- trains.first.arrival # {:scheduled=>"08:40", :expected=>"08:41"}
67
+ trains.first.arrival # {:scheduled=>2013-05-13 22:09:00 +0100, :expected=>2013-05-13 22:10:00 +0100}
58
68
 
59
- trains.first.departure # {:scheduled=>"08:41", :expected=>"08:41"}
69
+ trains.first.departure # {:scheduled=>2013-05-13 22:09:00 +0100, :expected=>2013-05-13 22:10:00 +0100}
60
70
 
61
71
  trains.first.duein # "2"
62
72
 
63
73
  trains.first.late? # 0 || 1
64
- </code></pre>
74
+ ```
65
75
 
66
- Check the **main.rb** for additional usage.
76
+ Check the [main.rb](main.rb) for additional usage.
77
+
78
+ Pull requests welcome, because there's damn all in it at the moment. Please accompany the pull request with an appropriate test, and if you can, an example here in the README.
79
+
80
+
81
+ [![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/oisin/ierail/trend.png)](https://bitdeli.com/free "Bitdeli Badge")
67
82
 
68
- Pull requests welcome, because there's damn all in it at the moment. Please accompany the pull request with an appropriate test.
data/ierail.gemspec CHANGED
@@ -2,16 +2,16 @@ require 'date'
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'ierail'
5
- s.version = '0.3.4'
5
+ s.version = '0.3.5'
6
6
  s.date = Date.today.to_s
7
7
  s.summary = "Irish Rail Train Schedule and Status API"
8
8
  s.description = "Irish Rail Train Schedule and Status API"
9
- s.authors = ["Oisin Hurley", "Gary Rafferty"]
9
+ s.authors = ["Oisin Hurley", "Gary Rafferty", "Michael Dever"]
10
10
  s.email = 'oi.sin@nis.io'
11
11
  s.files = `git ls-files`.split("\n")
12
12
  s.homepage = 'http://rubygems.org/gems/ierail'
13
- s.add_dependency 'nokogiri', '~> 1.5.0'
14
- s.add_dependency 'rest-client', '~> 1.6.7'
15
- s.add_dependency 'json', '~> 1.7.7'
16
- s.add_dependency 'tzinfo', '~> 0.3.37'
13
+ s.add_runtime_dependency 'json', '~> 1.7', '>= 1.7.7'
14
+ s.add_runtime_dependency 'rest-client', '~> 1.6', '>= 1.6.7'
15
+ s.add_runtime_dependency 'nokogiri', '~> 1.5', '>= 1.5.0'
16
+ s.add_runtime_dependency 'tzinfo', '~> 0.3', '>= 0.3.37'
17
17
  end
data/lib/ierail.rb CHANGED
@@ -6,6 +6,7 @@ require 'time'
6
6
  require 'train'
7
7
  require 'station'
8
8
  require 'station_data'
9
+ require 'train_movement'
9
10
  require 'core_ext'
10
11
 
11
12
  class IERail
@@ -71,11 +72,8 @@ class IERail
71
72
  #
72
73
  def stations
73
74
  ier = IERailGet.new("getAllStationsXML?", "arrayofobjstation", "objstation")
74
- retval = []
75
- ier.response.each do |s|
76
- retval << Station.new(s)
77
- end
78
- retval
75
+
76
+ ier.response.map { |s| Station.new(s) }
79
77
  end
80
78
 
81
79
  # Get ALL the trains! That are on the go at the moment.
@@ -92,11 +90,8 @@ class IERail
92
90
  #
93
91
  def trains
94
92
  ier = IERailGet.new("getCurrentTrainsXML?", "arrayofobjtrainpositions", "objtrainpositions")
95
- retval = []
96
- ier.response.each do |t|
97
- retval << Train.new(t)
98
- end
99
- retval
93
+
94
+ ier.response.map { |t| Train.new(t) }
100
95
  end
101
96
 
102
97
  # Get train information for a particular station, by station name. This gives data on trains thru that station
@@ -124,11 +119,8 @@ class IERail
124
119
  #
125
120
  def station(name)
126
121
  ier = IERailGet.new("getStationDataByNameXML?StationDesc=#{name}", "arrayofobjstationdata", "objstationdata")
127
- retval = []
128
- ier.response.each do |sd|
129
- retval << StationData.new(sd)
130
- end
131
- retval
122
+
123
+ ier.response.map { |sd| StationData.new(sd) }
132
124
  end
133
125
 
134
126
  # Get train information for a particular station, by station name, within the time period in minutes from now.
@@ -138,9 +130,28 @@ class IERail
138
130
  #
139
131
  def station_times(name, mins)
140
132
  ier = IERailGet.new("getStationDataByNameXML_withNumMins?StationDesc=#{name}&NumMins=#{mins}", "arrayofobjstationdata", "objstationdata")
133
+
134
+ ier.response.map { |sd| StationData.new(sd) }
135
+ end
136
+
137
+ # Get the movements of a particular train, by train code, on a date.
138
+ # If no date is supplied assume train has run/is running today.
139
+ #
140
+ # This gives all the stations that the train has or will be stopped at.
141
+ # Returns an array of TrainMovement objects, and each object responds to
142
+ # {
143
+ # obj#location => {code: "GLGRY", name: "Glenageary", stop_number: 1 (Stop number on route), type: "O" (Origin) \ "S" (Stop) \ "D" (Destination)}
144
+ # obj#train => {:code => "E909", :date => "20 Jan 2012", :origin => "Glenageary"}
145
+ # obj#arrival => {:scheduled => "10:09", :expected => "10:09", :actual => "10.09"}
146
+ # obj#departure => {:scheduled => "10:09", :expected => "10:09", :actual => "10.09"}
147
+ # obj#station => "Glenageary"
148
+ # }
149
+ #
150
+ def train_movements(code, date=Time.now)
151
+ ier = IERailGet.new("getTrainMovementsXML?TrainId=#{code}&TrainDate=#{date.strftime("%d/%m/%Y")}", "ArrayOfObjTrainMovements", "ObjTrainMovements")
141
152
  retval = []
142
- ier.response.each do |sd|
143
- retval << StationData.new(sd)
153
+ ier.response.each do |tm|
154
+ retval << TrainMovement.new(tm)
144
155
  end
145
156
  retval
146
157
  end
@@ -157,13 +168,12 @@ class IERail
157
168
  def find_station(partial)
158
169
  ier = IERailGet.new("getStationsFilterXML?StationText=#{partial}", "ArrayOfObjStationFilter", "objStationFilter")
159
170
  Struct.new("Station", :name, :description, :code)
160
- retval = []
161
- ier.response.each do |st|
162
- retval << Struct::Station.new(st['StationDesc_sp'],
163
- st['StationDesc'],
164
- st['StationCode'])
171
+
172
+ ier.response.map do |st|
173
+ Struct::Station.new(st['StationDesc_sp'],
174
+ st['StationDesc'],
175
+ st['StationCode'])
165
176
  end
166
- retval
167
177
  end
168
178
 
169
179
  # Get direction-specific train information for a particular station, by station name.
@@ -197,11 +207,8 @@ class IERail
197
207
  direction = name.to_s.split('_').first.capitalize
198
208
 
199
209
  ier = IERailGet.new("getStationDataByNameXML?StationDesc=#{args.first}", "arrayofobjstationdata", "objstationdata")
200
- retval = []
201
- ier.response.each do |sd|
202
- retval << StationData.new(sd) if sd['Direction'] == direction
203
- end
204
- retval
210
+
211
+ ier.response.select { |sd| sd['Direction'] == direction }.map { |sd| StationData.new(sd) }
205
212
  end
206
213
  end
207
214
  end
data/lib/station_data.rb CHANGED
@@ -18,12 +18,21 @@ class StationData
18
18
  @last_location = hash['Lastlocation']
19
19
  @duein = hash['Duein']
20
20
  @late = hash['Late']
21
- @exparrival = Time.parse hash['Exparrival']
22
- @expdepart = Time.parse hash['Expdepart']
23
- @scharrival = Time.parse hash['Scharrival']
24
- @schdepart = Time.parse hash['Schdepart']
21
+
22
+ # If train origin is station_name, then arrival times will be 00:00, so are adjusted to suit expected origin time.
23
+ # Likewise if destination is station_name, departure times should suit expected destination time.
24
+ # See: http://api.irishrail.ie/realtime/ Point 8
25
+ is_departure_station = @station_name.eql?(@origin)
26
+ is_terminating_station = @station_name.eql?(@destination)
27
+
28
+ @exparrival = is_departure_station ? @origin_time : Time.parse(hash['Exparrival'])
29
+ @expdepart = is_terminating_station ? @destination_time : Time.parse(hash['Expdepart'])
30
+ @scharrival = is_departure_station ? @origin_time + @late.to_i : Time.parse(hash['Scharrival'])
31
+ @schdepart = is_terminating_station ? @destination_time + @late.to_i : Time.parse(hash['Schdepart'])
25
32
  @direction = hash['Direction']
26
33
  @train_type = hash['Traintype']
34
+
35
+
27
36
  end
28
37
 
29
38
  def origin
@@ -0,0 +1,40 @@
1
+ class TrainMovement
2
+
3
+ attr_reader :location_full_name
4
+
5
+ def initialize hash
6
+ @train_code = hash['TrainCode']
7
+ @train_date = Time.parse hash['TrainDate']
8
+ @location_code = hash['LocationCode']
9
+ @location_full_name = hash['LocationFullName']
10
+ @location_order = hash['LocationOrder'].to_i
11
+ @location_type = hash['LocationType']
12
+ @train_origin = hash['TrainOrigin']
13
+ @scheduled_arrival = Time.parse hash['ScheduledArrival']
14
+ @scheduled_departure = Time.parse hash['ScheduledDeparture']
15
+ @expected_arrival = Time.parse hash['ExpectedArrival']
16
+ @expected_departure = Time.parse hash['ExpectedDeparture']
17
+ arrival_time = hash['Arrival']
18
+ departure_time = hash['Departure']
19
+ @arrival = arrival_time.nil? ? @expected_arrival : Time.parse(arrival_time)
20
+ @departure = departure_time.nil? ? @expected_departure : Time.parse(departure_time)
21
+ end
22
+
23
+ def location
24
+ {code: @location_code, name: @location_full_name, stop_number: @location_order, type: @location_type}
25
+ end
26
+
27
+ def arrival
28
+ {scheduled: @scheduled_arrival, expected: @expected_arrival, actual: @arrival}
29
+ end
30
+
31
+ def departure
32
+ {scheduled: @scheduled_departure, expected: @expected_departure, actual: @departure}
33
+ end
34
+
35
+ def train
36
+ {code: @train_code, date: @train_date, origin: @train_origin}
37
+ end
38
+
39
+ alias :station :location_full_name
40
+ end
data/test/unit/ierail.rb CHANGED
@@ -37,7 +37,7 @@ class IERailTest < MiniTest::Unit::TestCase
37
37
  #Thirty minutes from now
38
38
  thirty_mins = @now + (60 * 30)
39
39
  time = "#{thirty_mins.hour}:#{thirty_mins.min}" # "HH:MM"
40
- before_train = @ir.southbound_from('Malahide').before(time).sample
40
+ before_train = @ir.southbound_from('Dublin Connolly').before(time).sample
41
41
  assert before_train.expdepart <= thirty_mins
42
42
  end
43
43
 
@@ -45,7 +45,7 @@ class IERailTest < MiniTest::Unit::TestCase
45
45
  #Thirty minutes from now
46
46
  thirty_mins = @now + (60 * 30)
47
47
  time = "#{thirty_mins.hour}:#{thirty_mins.min}" # "HH:MM"
48
- after_train = @ir.southbound_from('Malahide').after(time).sample
48
+ after_train = @ir.southbound_from('Dublin Connolly').after(time).sample
49
49
  assert after_train.expdepart >= thirty_mins
50
50
  end
51
51
 
@@ -0,0 +1,50 @@
1
+ $:.unshift(File.join(File.dirname(__FILE__), '..','..', 'lib'))
2
+
3
+ require_relative 'helper'
4
+
5
+ require 'minitest/autorun'
6
+ require 'ierail'
7
+
8
+ class TrainMovementTest < MiniTest::Unit::TestCase
9
+ def setup
10
+ ir = IERail.new
11
+
12
+ train_code = ir.trains.sample.code #Use a random train code
13
+ @train_movement = ir.train_movements(train_code).sample #Use a random movement from the random train
14
+ end
15
+
16
+ def test_that_location_method_returns_a_hash
17
+ assert_equal @train_movement.location.class, Hash
18
+ end
19
+
20
+ def test_that_there_is_a_location_code_and_name_and_stop_number_and_type
21
+ refute_empty @train_movement.location[:code]
22
+ refute_empty @train_movement.location[:name]
23
+ refute_nil @train_movement.location[:stop_number]
24
+ refute_empty @train_movement.location[:type]
25
+ end
26
+
27
+ def test_that_arrival_method_returns_a_hash
28
+ assert_equal @train_movement.arrival.class, Hash
29
+ end
30
+
31
+ def test_that_there_is_an_arrival_sched_and_exp_and_actual
32
+ refute_nil @train_movement.arrival[:scheduled]
33
+ refute_nil @train_movement.arrival[:expected]
34
+ refute_nil @train_movement.arrival[:actual]
35
+ end
36
+
37
+ def test_that_departure_method_returns_a_hash
38
+ assert_equal @train_movement.departure.class, Hash
39
+ end
40
+
41
+ def test_that_there_is_a_departure_sched_and_exp_and_actual
42
+ refute_nil @train_movement.departure[:scheduled]
43
+ refute_nil @train_movement.departure[:expected]
44
+ refute_nil @train_movement.departure[:actual]
45
+ end
46
+
47
+ def test_that_it_responds_to_station
48
+ assert_respond_to @train_movement, :station
49
+ end
50
+ end
metadata CHANGED
@@ -1,70 +1,95 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ierail
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.4
4
+ version: 0.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Oisin Hurley
8
8
  - Gary Rafferty
9
+ - Michael Dever
9
10
  autorequire:
10
11
  bindir: bin
11
12
  cert_chain: []
12
- date: 2013-05-13 00:00:00.000000000 Z
13
+ date: 2014-04-11 00:00:00.000000000 Z
13
14
  dependencies:
14
15
  - !ruby/object:Gem::Dependency
15
- name: nokogiri
16
+ name: json
16
17
  requirement: !ruby/object:Gem::Requirement
17
18
  requirements:
18
- - - ~>
19
+ - - "~>"
19
20
  - !ruby/object:Gem::Version
20
- version: 1.5.0
21
+ version: '1.7'
22
+ - - ">="
23
+ - !ruby/object:Gem::Version
24
+ version: 1.7.7
21
25
  type: :runtime
22
26
  prerelease: false
23
27
  version_requirements: !ruby/object:Gem::Requirement
24
28
  requirements:
25
- - - ~>
29
+ - - "~>"
26
30
  - !ruby/object:Gem::Version
27
- version: 1.5.0
31
+ version: '1.7'
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: 1.7.7
28
35
  - !ruby/object:Gem::Dependency
29
36
  name: rest-client
30
37
  requirement: !ruby/object:Gem::Requirement
31
38
  requirements:
32
- - - ~>
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: '1.6'
42
+ - - ">="
33
43
  - !ruby/object:Gem::Version
34
44
  version: 1.6.7
35
45
  type: :runtime
36
46
  prerelease: false
37
47
  version_requirements: !ruby/object:Gem::Requirement
38
48
  requirements:
39
- - - ~>
49
+ - - "~>"
50
+ - !ruby/object:Gem::Version
51
+ version: '1.6'
52
+ - - ">="
40
53
  - !ruby/object:Gem::Version
41
54
  version: 1.6.7
42
55
  - !ruby/object:Gem::Dependency
43
- name: json
56
+ name: nokogiri
44
57
  requirement: !ruby/object:Gem::Requirement
45
58
  requirements:
46
- - - ~>
59
+ - - "~>"
47
60
  - !ruby/object:Gem::Version
48
- version: 1.7.7
61
+ version: '1.5'
62
+ - - ">="
63
+ - !ruby/object:Gem::Version
64
+ version: 1.5.0
49
65
  type: :runtime
50
66
  prerelease: false
51
67
  version_requirements: !ruby/object:Gem::Requirement
52
68
  requirements:
53
- - - ~>
69
+ - - "~>"
54
70
  - !ruby/object:Gem::Version
55
- version: 1.7.7
71
+ version: '1.5'
72
+ - - ">="
73
+ - !ruby/object:Gem::Version
74
+ version: 1.5.0
56
75
  - !ruby/object:Gem::Dependency
57
76
  name: tzinfo
58
77
  requirement: !ruby/object:Gem::Requirement
59
78
  requirements:
60
- - - ~>
79
+ - - "~>"
80
+ - !ruby/object:Gem::Version
81
+ version: '0.3'
82
+ - - ">="
61
83
  - !ruby/object:Gem::Version
62
84
  version: 0.3.37
63
85
  type: :runtime
64
86
  prerelease: false
65
87
  version_requirements: !ruby/object:Gem::Requirement
66
88
  requirements:
67
- - - ~>
89
+ - - "~>"
90
+ - !ruby/object:Gem::Version
91
+ version: '0.3'
92
+ - - ">="
68
93
  - !ruby/object:Gem::Version
69
94
  version: 0.3.37
70
95
  description: Irish Rail Train Schedule and Status API
@@ -73,9 +98,9 @@ executables: []
73
98
  extensions: []
74
99
  extra_rdoc_files: []
75
100
  files:
76
- - .coveralls.yml
77
- - .gitignore
78
- - .travis.yml
101
+ - ".coveralls.yml"
102
+ - ".gitignore"
103
+ - ".travis.yml"
79
104
  - Gemfile
80
105
  - Gemfile.lock
81
106
  - LICENSE.txt
@@ -87,12 +112,14 @@ files:
87
112
  - lib/station.rb
88
113
  - lib/station_data.rb
89
114
  - lib/train.rb
115
+ - lib/train_movement.rb
90
116
  - main.rb
91
117
  - test/unit/helper.rb
92
118
  - test/unit/ierail.rb
93
119
  - test/unit/station.rb
94
120
  - test/unit/station_data.rb
95
121
  - test/unit/train.rb
122
+ - test/unit/train_movement.rb
96
123
  homepage: http://rubygems.org/gems/ierail
97
124
  licenses: []
98
125
  metadata: {}
@@ -102,17 +129,17 @@ require_paths:
102
129
  - lib
103
130
  required_ruby_version: !ruby/object:Gem::Requirement
104
131
  requirements:
105
- - - ! '>='
132
+ - - ">="
106
133
  - !ruby/object:Gem::Version
107
134
  version: '0'
108
135
  required_rubygems_version: !ruby/object:Gem::Requirement
109
136
  requirements:
110
- - - ! '>='
137
+ - - ">="
111
138
  - !ruby/object:Gem::Version
112
139
  version: '0'
113
140
  requirements: []
114
141
  rubyforge_project:
115
- rubygems_version: 2.0.3
142
+ rubygems_version: 2.2.2
116
143
  signing_key:
117
144
  specification_version: 4
118
145
  summary: Irish Rail Train Schedule and Status API