atco 1.0.0 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 91d4d697f6d487218aa3def133f0104257141ed8fb18b93be2c3f0c52ac92a6e
4
- data.tar.gz: 213d51b686a0076c69f26b6d18173dd2b767eaf24db17f7e0cdc011406b94705
3
+ metadata.gz: 82cd5858676f7202932ecbe6d68846066019bd75c5637c33a44ec3eaf83fe599
4
+ data.tar.gz: 144dad716574ca9f45f63170193de8c1115edc6a4ece1557516c57e9d1d250a3
5
5
  SHA512:
6
- metadata.gz: fb0ccef50c6a0490c9b87b0b01a7179bec8ca755d594f52193ef6220ef6733e2c8ed600f46043c3a0a38038f3290a8687f1828adfe893dac7dad5c7413b23c89
7
- data.tar.gz: 6ba15c31b4cfb1873577af0fe50c62c6325780d9f9c3c6ddb124cfe91397dd2808382757f1198f492ea6fbbe2a21131e010b49ac80a757f33041a3ff57db1d9f
6
+ metadata.gz: 947c0a1bbfa755bacb1d907c50f90720e98dcebfef88d500b6e418c652827846ea2c32372e8aed4fdd8e1e4aad71ce9f61acd1f0c51b0dd68bd696d1e9774a98
7
+ data.tar.gz: 9556d7e0bc6cd268b326475c03c3136a59f5f0066db0d1a84fa7510ee9e4eeb0a0f8cc1a63cb1869bd7165184eb54481afdb984d0cd2bb79bc7c6dcfe21a1e32
data/README.md CHANGED
@@ -23,7 +23,7 @@ gem install atco
23
23
  irb
24
24
 
25
25
 
26
- require 'rubygems
26
+ require 'rubygems'
27
27
  require 'atco'
28
28
 
29
29
  result = Atco.parse('filename.cif')
@@ -34,4 +34,4 @@ result = Atco.parse('SVRTMAO009A-20091005.cif) # an example data file in the rep
34
34
  locations: […],
35
35
  journies: {…}
36
36
  }
37
- ```
37
+ ```
data/Rakefile CHANGED
@@ -1,12 +1,19 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'bundler/gem_tasks'
4
- require 'rspec/core/rake_task'
3
+ require "bundler/gem_tasks"
5
4
 
6
5
  begin
6
+ require "rspec/core/rake_task"
7
7
  RSpec::Core::RakeTask.new(:spec)
8
8
  rescue LoadError
9
- puts 'RSpec, or one of its dependencies, is not available. Install it with: bundle install'
9
+ puts "RSpec, or one of its dependencies, is not available. Install it with: bundle install"
10
10
  end
11
11
 
12
- task default: :spec
12
+ begin
13
+ require "rubocop/rake_task"
14
+ RuboCop::RakeTask.new
15
+ rescue LoadError
16
+ puts "rubocop, or one of its dependencies, is not available. Install it with: bundle install"
17
+ end
18
+
19
+ task default: %i[spec rubocop]
data/lib/atco/journey.rb CHANGED
@@ -1,11 +1,12 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Atco
4
+ # Atco::Journey is a data class to abstract ATCO-CIF Journey records.
4
5
  class Journey
5
6
  attr_accessor :vehicle_type, :registration_number, :identifier, :operator, :route_number, :first_date_of_operation,
6
7
  :running_board, :last_date_of_operation, :school_term_time, :route_direction, :bank_holidays, :stops
7
8
 
8
- def initialize(data)
9
+ def initialize(data) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
9
10
  @mondays = parse_boolean_int data[:operates_on_mondays]
10
11
  @tuesdays = parse_boolean_int data[:operates_on_tuesdays]
11
12
  @wednesdays = parse_boolean_int data[:operates_on_wednesdays]
@@ -61,10 +62,10 @@ module Atco
61
62
  end
62
63
 
63
64
  def parse_boolean_int(string)
64
- string && string == '1' ? true : false
65
+ string && string == "1"
65
66
  end
66
67
 
67
- def to_json(*args)
68
+ def to_json(*attrs) # rubocop:disable Metrics/MethodLength
68
69
  {
69
70
  vehicle_type: @vehicle_type,
70
71
  registration_number: @registration_number,
@@ -78,7 +79,7 @@ module Atco
78
79
  route_direction: @route_direction,
79
80
  bank_holidays: @bank_holidays,
80
81
  stops: @stops
81
- }.to_json(*args)
82
+ }.to_json(*attrs)
82
83
  end
83
84
  end
84
85
  end
data/lib/atco/location.rb CHANGED
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Atco
4
+ # Atco::Location is a data class to abstract ATCO-CIF Location records.
4
5
  class Location
5
6
  attr_accessor :name, :identifier, :easting, :northing, :gazeteer_code
6
7
 
@@ -12,14 +13,14 @@ module Atco
12
13
  @gazeteer_code = location_header[:gazetteer_code]
13
14
  end
14
15
 
15
- def to_json(*a)
16
+ def to_json(*attrs)
16
17
  {
17
18
  name: @name,
18
19
  identifier: @identifier,
19
20
  easting: @easting,
20
21
  northing: @northing,
21
22
  gazeteer_code: @gazeteer_code
22
- }.to_json(*a)
23
+ }.to_json(*attrs)
23
24
  end
24
25
  end
25
26
  end
data/lib/atco/stop.rb CHANGED
@@ -1,20 +1,21 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Atco
4
+ # Atco::Stop is a class to abstract ATCO-CIF Origin, Intermediate and Destination (Stop) records.
4
5
  class Stop
5
6
  attr_accessor :bay_number, :location, :timing_point_indicator, :fare_stage_indicator, :published_departure_time,
6
7
  :record_identity
7
8
 
8
9
  def origin?
9
- @record_identity == 'QO'
10
+ @record_identity == "QO"
10
11
  end
11
12
 
12
13
  def intermediate?
13
- @record_identity == 'QI'
14
+ @record_identity == "QI"
14
15
  end
15
16
 
16
17
  def destination?
17
- @record_identity == 'QT'
18
+ @record_identity == "QT"
18
19
  end
19
20
 
20
21
  def initialize(data)
@@ -26,7 +27,7 @@ module Atco
26
27
  @record_identity = data[:record_identity]
27
28
  end
28
29
 
29
- def to_json(*args)
30
+ def to_json(*attrs)
30
31
  {
31
32
  record_identity: @record_identity,
32
33
  location: @location,
@@ -34,7 +35,7 @@ module Atco
34
35
  timing_point_indicator: @timing_point_indicator,
35
36
  fare_stage_indicator: @fare_stage_indicator,
36
37
  bay_number: @bay_number
37
- }.to_json(*args)
38
+ }.to_json(*attrs)
38
39
  end
39
40
  end
40
41
  end
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Atco
4
+ VERSION = "1.0.2"
5
+ end
data/lib/atco.rb CHANGED
@@ -1,31 +1,28 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- $LOAD_PATH.unshift(File.dirname(__FILE__)) unless
4
- $LOAD_PATH.include?(File.dirname(__FILE__)) || $LOAD_PATH.include?(__dir__)
5
-
6
- require 'open3'
7
- require 'tempfile'
8
- require 'atco/location'
9
- require 'atco/journey'
10
- require 'atco/stop'
11
-
12
- module Atco
13
- VERSION = '0.0.1'
14
-
15
- class << self
3
+ require "open3"
4
+ require "tempfile"
5
+ require_relative "atco/location"
6
+ require_relative "atco/journey"
7
+ require_relative "atco/stop"
8
+ require_relative "atco/version"
9
+
10
+ # Public: Atco is a module that provides a parser for the ATCO-CIF data format.
11
+ module Atco # rubocop:disable Metrics/ModuleLength
12
+ class << self # rubocop:disable Metrics/ClassLength
16
13
  @path = nil
17
- @@methods = {
18
- bank_holiday: 'QH',
19
- operator: 'QP',
20
- additional_location_info: 'QB',
21
- location: 'QL',
22
- destination: 'QT',
23
- intermediate: 'QI',
24
- origin: 'QO',
25
- journey_header: 'QS'
26
- }
27
-
28
- def parse(file)
14
+ METHODS = {
15
+ bank_holiday: "QH",
16
+ operator: "QP",
17
+ additional_location_info: "QB",
18
+ location: "QL",
19
+ destination: "QT",
20
+ intermediate: "QI",
21
+ origin: "QO",
22
+ journey_header: "QS"
23
+ }.freeze
24
+
25
+ def parse(file) # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity, Metrics/MethodLength, Metrics/PerceivedComplexity
29
26
  @path = File.expand_path(file)
30
27
  data = File.readlines(@path)
31
28
 
@@ -41,13 +38,13 @@ module Atco
41
38
  header = parse_header(line)
42
39
  next
43
40
  end
44
- @@methods.each do |method, identifier|
41
+ METHODS.each do |method, identifier|
45
42
  object = send("parse_#{method}", line)
46
43
  next unless object[:record_identity] && object[:record_identity] == identifier
47
44
 
48
- current_journey = object if object[:record_identity] && object[:record_identity] == @@methods[:journey_header]
49
- if object[:record_identity] && (object[:record_identity] == @@methods[:location] || object[:record_identity] == @@methods[:additional_location_info])
50
- if object[:record_identity] == @@methods[:location]
45
+ current_journey = object if object[:record_identity] && object[:record_identity] == METHODS[:journey_header]
46
+ if object[:record_identity] && (object[:record_identity] == METHODS[:location] || object[:record_identity] == METHODS[:additional_location_info]) # rubocop:disable Layout/LineLength
47
+ if object[:record_identity] == METHODS[:location]
51
48
  current_location = object
52
49
  else
53
50
  locations << Location.new(current_location, object)
@@ -150,7 +147,7 @@ module Atco
150
147
  }
151
148
  end
152
149
 
153
- def parse_journey_header(string)
150
+ def parse_journey_header(string) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
154
151
  {
155
152
  record_identity: string[0, 2],
156
153
  transaction_type: string[2, 1],
data/spec/atco_spec.rb CHANGED
@@ -1,174 +1,198 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "#{File.dirname(__FILE__)}/spec_helper"
4
- require 'json'
3
+ require "json"
5
4
 
6
- describe Atco do
7
- before(:all) do
5
+ RSpec.describe Atco do # rubocop:disable Metrics/BlockLength
6
+ it "has a version number" do
7
+ expect(Atco::VERSION).not_to be nil
8
8
  end
9
9
 
10
- it 'should output file for debugging!' do
11
- result = Atco.parse('spec/fixtures/example.cif')
12
- File.open('test.output', 'w+') do |f|
13
- f.flush
14
- f.write(JSON.pretty_generate(result))
15
- end
16
- end
17
-
18
- it 'should parse header from fixture' do
19
- result = Atco.parse('spec/fixtures/example.cif')
20
- expect result[:header] == {
21
- file_type: 'ATCO-CIF',
22
- file_originator: 'Electronic Registration',
23
- source_product: 'MIA 4.20.18',
24
- version: '5.0',
25
- production_datetime: '20090915113809'
26
- }
10
+ it "should parse header from fixture" do
11
+ result = Atco.parse("spec/fixtures/example.cif")
12
+ expect(result[:header]).to eq(
13
+ {
14
+ file_type: "ATCO-CIF",
15
+ file_originator: "Electronic Registration",
16
+ source_product: "MIA 4.20.18",
17
+ version: "5.0",
18
+ production_datetime: "20090915113809"
19
+ }
20
+ )
27
21
  end
28
22
 
29
- it 'should parse locations from fixture' do
30
- result = Atco.parse('spec/fixtures/example.cif')
31
- expect result[:header] == {
32
- file_type: 'ATCO-CIF',
33
- file_originator: 'Electronic Registration',
34
- source_product: 'MIA 4.20.18',
35
- version: '5.0',
36
- production_datetime: '20090915113809'
37
- }
23
+ it "should parse locations from fixture" do
24
+ result = Atco.parse("spec/fixtures/example.cif")
25
+ expect(result[:header]).to eq(
26
+ {
27
+ file_type: "ATCO-CIF",
28
+ file_originator: "Electronic Registration",
29
+ source_product: "MIA 4.20.18",
30
+ version: "5.0",
31
+ production_datetime: "20090915113809"
32
+ }
33
+ )
38
34
  end
39
35
 
40
- it 'should parse header' do
41
- expect Atco.parse_header("ATCO-CIF0500Electronic Registration MIA 4.20.18 20090915113809\r\n") == {
42
- file_type: 'ATCO-CIF',
43
- version: '5.0',
44
- file_originator: 'Electronic Registration',
45
- source_product: 'MIA 4.20.18',
46
- production_datetime: '20090915113809'
47
- }
36
+ it "should parse header" do
37
+ expect(Atco.parse_header("ATCO-CIF0500Electronic Registration MIA 4.20.18 20090915113809\r\n")).to eq(
38
+ {
39
+ file_type: "ATCO-CIF",
40
+ version: "5.0",
41
+ file_originator: "Electronic Registration",
42
+ source_product: "MIA 4.20.18",
43
+ production_datetime: "20090915113809"
44
+ }
45
+ )
48
46
  end
49
47
 
50
- it 'should parse bank holiday' do
51
- expect Atco.parse_bank_holiday('QHN20061225') == {
52
- record_identity: 'QH',
53
- transaction_type: 'N',
54
- date_of_bank_holiday: '20061225'
55
- }
48
+ it "should parse bank holiday" do
49
+ expect(Atco.parse_bank_holiday("QHN20061225")).to eq(
50
+ {
51
+ record_identity: "QH",
52
+ transaction_type: "N",
53
+ date_of_bank_holiday: "20061225"
54
+ }
55
+ )
56
56
  end
57
57
 
58
- it 'should parse operator' do
59
- expect Atco.parse_operator("QPNTM Translink Metro Translink Metro \r\n") == {
60
- record_identity: 'QP',
61
- transaction_type: 'N',
62
- operator: 'TM',
63
- operator_short_form: 'Translink Metro',
64
- operator_legal_name: 'Translink Metro'
65
- }
58
+ it "should parse operator" do
59
+ expect(Atco.parse_operator("QPNTM Translink Metro Translink Metro \r\n")).to eq(
60
+ {
61
+ record_identity: "QP",
62
+ transaction_type: "N",
63
+ operator: "TM",
64
+ operator_short_form: "Translink Metro",
65
+ operator_legal_name: "Translink Metro"
66
+ }
67
+ )
66
68
  end
67
69
 
68
- it 'should parse additional location information' do
69
- expect Atco.parse_additional_location_info("QBN700000001252 328622 367433 \r\n") == {
70
- record_identity: 'QB',
71
- transaction_type: 'N',
72
- location: '700000001252',
73
- grid_reference_easting: '328622',
74
- grid_reference_northing: '367433'
75
- }
70
+ it "should parse additional location information" do
71
+ expect(Atco.parse_additional_location_info("QBN700000001252 328622 367433 \r\n")).to eq(
72
+ {
73
+ record_identity: "QB",
74
+ transaction_type: "N",
75
+ location: "700000001252",
76
+ grid_reference_easting: "328622",
77
+ grid_reference_northing: "367433"
78
+ }
79
+ )
76
80
  end
77
81
 
78
- it 'should parse location' do
79
- expect Atco.parse_location("QLN700000001252Conway (River Rd) 1\r\n") == {
80
- record_identity: 'QL',
81
- transaction_type: 'N',
82
- location: '700000001252',
83
- full_location: 'Conway (River Rd)',
84
- gazetteer_code: '1'
85
- }
82
+ it "should parse location" do
83
+ expect(Atco.parse_location("QLN700000001252Conway (River Rd) 1\r\n")).to eq(
84
+ {
85
+ record_identity: "QL",
86
+ transaction_type: "N",
87
+ location: "700000001252",
88
+ full_location: "Conway (River Rd)",
89
+ gazetteer_code: "1"
90
+ }
91
+ )
86
92
  end
87
93
 
88
94
  # QT7000000012520605 T1F0
89
- it 'should parse destination' do
90
- expect Atco.parse_destination("QT7000000012520605 T1F0\r\n") == {
91
- record_identity: 'QT',
92
- location: '700000001252',
93
- published_arrival_time: '0605',
94
- bay_number: '',
95
- timing_point_indicator: 'T1',
96
- fare_stage_indicator: 'F0'
97
- }
95
+ it "should parse destination" do
96
+ expect(Atco.parse_destination("QT7000000012520605 T1F0\r\n")).to eq(
97
+ {
98
+ record_identity: "QT",
99
+ location: "700000001252",
100
+ published_arrival_time: "0605",
101
+ bay_number: "",
102
+ timing_point_indicator: "T1",
103
+ fare_stage_indicator: "F0"
104
+ }
105
+ )
98
106
  end
99
107
 
100
- it 'should parse intermediate' do
101
- expect Atco.parse_intermediate("QI70000000125607120712B T1F0\r\n") == {
102
- record_identity: 'QI',
103
- location: '700000001256',
104
- published_arrival_time: '0712',
105
- published_departure_time: '0712',
106
- activity_flag: 'B',
107
- bay_number: '',
108
- timing_point_indicator: 'T1',
109
- fare_stage_indicator: 'F0'
110
- }
108
+ it "should parse intermediate" do
109
+ expect(Atco.parse_intermediate("QI70000000125607120712B T1F0\r\n")).to eq(
110
+ {
111
+ record_identity: "QI",
112
+ location: "700000001256",
113
+ published_arrival_time: "0712",
114
+ published_departure_time: "0712",
115
+ activity_flag: "B",
116
+ bay_number: "",
117
+ timing_point_indicator: "T1",
118
+ fare_stage_indicator: "F0"
119
+ }
120
+ )
111
121
  end
112
122
 
113
- it 'should parse origin' do
114
- expect Atco.parse_origin("QO7000000012520730 T1F0\r\n") == {
115
- record_identity: 'QO',
116
- location: '700000001252',
117
- published_departure_time: '0730',
118
- bay_number: '',
119
- timing_point_indicator: 'T1',
120
- fare_stage_indicator: 'F0'
121
- }
123
+ it "should parse origin" do
124
+ expect(Atco.parse_origin("QO7000000012520730 T1F0\r\n")).to eq(
125
+ {
126
+ record_identity: "QO",
127
+ location: "700000001252",
128
+ published_departure_time: "0730",
129
+ bay_number: "",
130
+ timing_point_indicator: "T1",
131
+ fare_stage_indicator: "F0"
132
+ }
133
+ )
122
134
  end
123
135
 
124
- it 'should parse journey header' do
125
- expect Atco.parse_journey_header("QSNTM 13986520091005 1111100 9A 9018 0 I\r\n") == {
126
- record_identity: 'QS',
127
- transaction_type: 'N',
128
- operator: 'TM',
129
- unique_journey_identifier: '139865',
130
- first_date_of_operation: '20091005',
131
- last_date_of_operation: '',
132
- operates_on_mondays: '1',
133
- operates_on_tuesdays: '1',
134
- operates_on_wednesdays: '1',
135
- operates_on_thursdays: '1',
136
- operates_on_fridays: '1',
137
- operates_on_saturdays: '0',
138
- operates_on_sundays: '0',
139
- school_term_time: '',
140
- bank_holidays: '',
141
- route_number: '9A',
142
- running_board: '9018',
143
- vehicle_type: '0',
144
- registration_number: '',
145
- route_direction: 'I'
146
- }
136
+ it "should parse journey header" do
137
+ expect(Atco.parse_journey_header("QSNTM 13986520091005 1111100 9A 9018 0 I\r\n")).to eq(
138
+ {
139
+ record_identity: "QS",
140
+ transaction_type: "N",
141
+ operator: "TM",
142
+ unique_journey_identifier: "139865",
143
+ first_date_of_operation: "20091005",
144
+ last_date_of_operation: "",
145
+ operates_on_mondays: "1",
146
+ operates_on_tuesdays: "1",
147
+ operates_on_wednesdays: "1",
148
+ operates_on_thursdays: "1",
149
+ operates_on_fridays: "1",
150
+ operates_on_saturdays: "0",
151
+ operates_on_sundays: "0",
152
+ school_term_time: "",
153
+ bank_holidays: "",
154
+ route_number: "9A",
155
+ running_board: "9018",
156
+ vehicle_type: "0",
157
+ registration_number: "",
158
+ route_direction: "I"
159
+ }
160
+ )
147
161
  end
148
162
 
149
- describe 'with example.cif' do
163
+ describe "with example.cif" do # rubocop:disable Metrics/BlockLength
150
164
  before(:all) do
151
- @atco = Atco.parse('spec/fixtures/example.cif')
165
+ @atco = Atco.parse("spec/fixtures/example.cif")
152
166
  end
153
167
 
154
- it 'should parse 1 journey' do
155
- expect @atco[:journeys].size == 1
168
+ it "should parse 1 journey" do
169
+ expect(@atco[:journeys].size).to eq(1)
156
170
  end
157
171
 
158
- it 'should parse journeys into Atco::Joruney objects' do
159
- expect(@atco[:journeys]['139748']).to be_a_kind_of(Atco::Journey)
172
+ it "should parse journeys into Atco::Joruney objects" do
173
+ expect(@atco[:journeys]["139748"]).to be_a_kind_of(Atco::Journey)
160
174
  end
161
175
 
162
- it 'should parse 6 stops for joureny 139748' do
163
- expect @atco[:journeys]['139748'].stops.size == 6
176
+ it "should parse 6 stops for journey 139748" do
177
+ expect(@atco[:journeys]["139748"].stops.size).to eq(6)
164
178
  end
165
179
 
166
- it 'should parse 6 stops for joureny 139748' do
167
- expect @atco[:journeys]['139748'].stops.size == 6
180
+ it "should parse 2 locations" do
181
+ expect(@atco[:locations].size).to eq(2)
168
182
  end
169
183
 
170
- it 'should parse 2 locations' do
171
- expect @atco[:locations].size == 2
184
+ it "should output file as JSON" do
185
+ output = File.join(File.dirname(__FILE__), "artefacts", "test.json")
186
+ File.open(output, "w+") do |f|
187
+ f.flush
188
+ f.write(JSON.pretty_generate(@atco))
189
+ end
190
+
191
+ expect(File.exist?(output)).to be true
192
+
193
+ data = File.read(output)
194
+ json = JSON.parse(data)
195
+ expect(json).to be_a(Hash)
172
196
  end
173
197
  end
174
198
  end
data/spec/spec_helper.rb CHANGED
@@ -1,6 +1,15 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'rubygems'
4
- require 'rspec'
3
+ require "atco"
5
4
 
6
- require "#{File.dirname(__FILE__)}/../lib/atco"
5
+ RSpec.configure do |config|
6
+ # Enable flags like --only-failures and --next-failure
7
+ config.example_status_persistence_file_path = ".rspec_status"
8
+
9
+ # Disable RSpec exposing methods globally on `Module` and `main`
10
+ config.disable_monkey_patching!
11
+
12
+ config.expect_with :rspec do |c|
13
+ c.syntax = :expect
14
+ end
15
+ end
metadata CHANGED
@@ -1,43 +1,43 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: atco
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Rice
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-04-04 00:00:00.000000000 Z
11
+ date: 2024-04-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0'
19
+ version: '13.0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ">="
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0'
26
+ version: '13.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rspec
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ">="
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '0'
33
+ version: '3.9'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ">="
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '0'
40
+ version: '3.9'
41
41
  description: Simple and opinionated library for parsing ATCO .cif files to JSON with
42
42
  Ruby
43
43
  email: me@davidjrice.co.uk
@@ -48,11 +48,11 @@ extra_rdoc_files:
48
48
  files:
49
49
  - README.md
50
50
  - Rakefile
51
- - VERSION
52
51
  - lib/atco.rb
53
52
  - lib/atco/journey.rb
54
53
  - lib/atco/location.rb
55
54
  - lib/atco/stop.rb
55
+ - lib/atco/version.rb
56
56
  - spec/atco_spec.rb
57
57
  - spec/fixtures/example.cif
58
58
  - spec/fixtures/example.json
@@ -70,7 +70,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
70
  requirements:
71
71
  - - ">="
72
72
  - !ruby/object:Gem::Version
73
- version: '0'
73
+ version: 2.7.0
74
74
  required_rubygems_version: !ruby/object:Gem::Requirement
75
75
  requirements:
76
76
  - - ">="
data/VERSION DELETED
@@ -1 +0,0 @@
1
- 1.0.0