cineworld_uk 2.1.6 → 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +22 -3
  3. data/README.md +56 -14
  4. data/Rakefile +57 -1
  5. data/cineworld_uk.gemspec +1 -2
  6. data/lib/cineworld_uk/cinema.rb +113 -182
  7. data/lib/cineworld_uk/internal/api_response.rb +74 -0
  8. data/lib/cineworld_uk/internal/parser/api/cinema_address.rb +81 -0
  9. data/lib/cineworld_uk/internal/parser/api/film.rb +46 -0
  10. data/lib/cineworld_uk/internal/parser/api/film_lookup.rb +38 -0
  11. data/lib/cineworld_uk/internal/parser/api/performance.rb +46 -0
  12. data/lib/cineworld_uk/internal/parser/api/performances_by_day.rb +50 -0
  13. data/lib/cineworld_uk/internal/title_sanitizer.rb +56 -52
  14. data/lib/cineworld_uk/performance.rb +78 -0
  15. data/lib/cineworld_uk/version.rb +2 -2
  16. data/lib/cineworld_uk.rb +11 -8
  17. data/test/fixtures/api/cinema-detail-10.json +1 -0
  18. data/test/fixtures/api/cinema-detail-21.json +1 -0
  19. data/test/fixtures/api/cinema-detail-3.json +1 -0
  20. data/test/fixtures/api/cinema-detail-96.json +1 -0
  21. data/test/fixtures/api/cinema-list.json +1 -0
  22. data/test/fixtures/api/dates-3.json +1 -0
  23. data/test/fixtures/api/film-list-comingsoon.json +1 -0
  24. data/test/fixtures/api/film-list.json +1 -0
  25. data/test/fixtures/api/performances-tomorrow-3.json +1 -0
  26. data/test/lib/cineworld_uk/cinema_test.rb +96 -197
  27. data/test/lib/cineworld_uk/internal/api_response_test.rb +85 -0
  28. data/test/lib/cineworld_uk/internal/parser/api/cinema_address_test.rb +93 -0
  29. data/test/lib/cineworld_uk/internal/parser/api/film_lookup_test.rb +30 -0
  30. data/test/lib/cineworld_uk/internal/parser/api/film_test.rb +169 -0
  31. data/test/lib/cineworld_uk/internal/parser/api/performance_test.rb +62 -0
  32. data/test/lib/cineworld_uk/internal/title_sanitizer_test.rb +1 -1
  33. data/test/lib/cineworld_uk/{screening_test.rb → performance_test.rb} +36 -48
  34. data/test/support/fixture_reader.rb +44 -0
  35. metadata +48 -59
  36. data/lib/cineworld_uk/film.rb +0 -65
  37. data/lib/cineworld_uk/internal/film_with_screenings_parser.rb +0 -69
  38. data/lib/cineworld_uk/internal/screening_parser.rb +0 -132
  39. data/lib/cineworld_uk/internal/website.rb +0 -35
  40. data/lib/cineworld_uk/internal/whatson_parser.rb +0 -36
  41. data/lib/cineworld_uk/screening.rb +0 -87
  42. data/test/fixture_updater.rb +0 -64
  43. data/test/fixtures/cinemas.html +0 -513
  44. data/test/fixtures/information/brighton.html +0 -1268
  45. data/test/fixtures/information/bristol.html +0 -1265
  46. data/test/fixtures/whatson/brighton/film_first.html +0 -207
  47. data/test/fixtures/whatson/brighton/film_last.html +0 -62
  48. data/test/fixtures/whatson/brighton/film_second.html +0 -347
  49. data/test/fixtures/whatson/brighton.html +0 -7508
  50. data/test/fixtures/whatson/glasgow-imax-at-gsc/film_first.html +0 -182
  51. data/test/fixtures/whatson/the-o2-greenwich/film_first.html +0 -167
  52. data/test/lib/cineworld_uk/film_test.rb +0 -142
  53. data/test/lib/cineworld_uk/internal/film_with_screenings_parser_test.rb +0 -101
  54. data/test/lib/cineworld_uk/internal/website_test.rb +0 -57
  55. data/test/lib/cineworld_uk/internal/whatson_parser_test.rb +0 -58
@@ -0,0 +1,169 @@
1
+ require_relative '../../../../../test_helper'
2
+ require_relative '../../../../../support/fixture_reader'
3
+
4
+ describe CineworldUk::Internal::Parser::Api::Film do
5
+ include Support::FixtureReader
6
+
7
+ let(:described_class) { CineworldUk::Internal::Parser::Api::Film }
8
+ let(:data) { random_film }
9
+
10
+ describe '#id' do
11
+ subject { described_class.new(data).id }
12
+
13
+ it 'is an integer' do
14
+ subject.must_be_instance_of(Fixnum)
15
+ end
16
+
17
+ it 'is the film id from the data' do
18
+ subject.must_equal(data['edi'])
19
+ end
20
+ end
21
+
22
+ describe '#dimension' do
23
+ subject { described_class.new(data).dimension }
24
+
25
+ it 'is a string' do
26
+ subject.must_be_instance_of(String)
27
+ end
28
+
29
+ it 'is 2d or 3d' do
30
+ subject.must_match(/[23]d/)
31
+ end
32
+
33
+ describe 'hash["format"] is "2D"' do
34
+ let(:data) { random_film.merge('format' => '2D') }
35
+
36
+ it 'is 2d' do
37
+ subject.must_equal('2d')
38
+ end
39
+ end
40
+
41
+ describe 'hash["format"] is "3D"' do
42
+ let(:data) { random_film.merge('format' => '3D') }
43
+
44
+ it 'is 3d' do
45
+ subject.must_equal('3d')
46
+ end
47
+ end
48
+
49
+ describe 'hash["format"] is "IMAX"' do
50
+ let(:data) { random_film.merge('format' => 'IMAX') }
51
+
52
+ it 'is 2d' do
53
+ subject.must_equal('2d')
54
+ end
55
+ end
56
+
57
+ describe 'hash["format"] is "IMAX3D"' do
58
+ let(:data) { random_film.merge('format' => 'IMAX3D') }
59
+
60
+ it 'is 3d' do
61
+ subject.must_equal('3d')
62
+ end
63
+ end
64
+ end
65
+
66
+ describe '#name' do
67
+ subject { described_class.new(data).name }
68
+
69
+ it 'is a string' do
70
+ subject.must_be_instance_of(String)
71
+ end
72
+
73
+ describe 'hash["originalTitle"] is different' do
74
+ let(:data) do
75
+ random_film.merge('originalTitle' => 'Original Title',
76
+ 'title' => 'Title')
77
+ end
78
+
79
+ it 'is the original title' do
80
+ subject.must_equal('Original Title')
81
+ end
82
+ end
83
+
84
+ describe 'original title is unsanitized' do
85
+ let(:data) { random_film.merge('originalTitle' => 'ROH: Something') }
86
+
87
+ it 'is sanitized' do
88
+ subject.must_equal('Royal Opera House: Something')
89
+ end
90
+ end
91
+ end
92
+
93
+ describe '#variant' do
94
+ subject { described_class.new(data).variant }
95
+
96
+ it 'is a sorted array of strings' do
97
+ subject.must_be_instance_of(Array)
98
+ subject.each { |element| element.must_be_instance_of(String) }
99
+ subject.sort.must_equal(subject)
100
+ end
101
+
102
+ describe 'hash["title"] includes "Movies For Juniors"' do
103
+ let(:data) do
104
+ random_film.merge('title' => 'Movies For Juniors - Something')
105
+ end
106
+
107
+ it 'includes "kids"' do
108
+ subject.must_include('kids')
109
+ end
110
+ end
111
+
112
+ describe 'hash["format"] is "IMAX3D"' do
113
+ let(:data) do
114
+ random_film.merge('title' => 'nothing', 'format' => 'IMAX3D')
115
+ end
116
+
117
+ it 'includes "imax"' do
118
+ subject.must_include('imax')
119
+ end
120
+ end
121
+
122
+ describe 'hash["format"] is "IMAX"' do
123
+ let(:data) do
124
+ random_film.merge('format' => 'IMAX')
125
+ end
126
+
127
+ it 'includes "imax"' do
128
+ subject.must_include('imax')
129
+ end
130
+ end
131
+
132
+ describe 'hash["title"] includes "Unlimited Screening"' do
133
+ let(:data) do
134
+ random_film.merge('title' => 'Something Unlimited Screening')
135
+ end
136
+
137
+ it 'includes "members"' do
138
+ subject.must_include('members')
139
+ end
140
+ end
141
+
142
+ describe 'hash["title"] includes "with Live Q And A"' do
143
+ let(:data) do
144
+ random_film.merge('title' => 'Something With Live Q And A')
145
+ end
146
+
147
+ it 'includes "q&a"' do
148
+ subject.must_include('q&a')
149
+ end
150
+ end
151
+
152
+ describe 'combination' do
153
+ let(:data) do
154
+ random_film.merge('format' => 'IMAX',
155
+ 'title' => 'Something Unlimited Screening')
156
+ end
157
+
158
+ it 'includes "members"' do
159
+ subject.must_include('imax', 'members')
160
+ end
161
+ end
162
+ end
163
+
164
+ private
165
+
166
+ def random_film
167
+ JSON.parse(film_list_json)['films'].sample
168
+ end
169
+ end
@@ -0,0 +1,62 @@
1
+ require_relative '../../../../../test_helper'
2
+ require_relative '../../../../../support/fixture_reader'
3
+
4
+ describe CineworldUk::Internal::Parser::Api::Performance do
5
+ include Support::FixtureReader
6
+
7
+ let(:described_class) { CineworldUk::Internal::Parser::Api::Performance }
8
+ let(:data) { random_performance }
9
+
10
+ before { WebMock.disable_net_connect! }
11
+
12
+ describe '#booking_url' do
13
+ subject { described_class.new(data).booking_url }
14
+
15
+ it 'should be a url on the cineworld website' do
16
+ subject.must_match(%r{cineworld.co.uk/booking\?})
17
+ end
18
+ end
19
+
20
+ describe '#film_id' do
21
+ subject { described_class.new(data).film_id }
22
+
23
+ it 'should be a six digit integer' do
24
+ subject.must_be_instance_of(Fixnum)
25
+ subject.must_be :>, 10_000
26
+ end
27
+ end
28
+
29
+ describe '#starting_at' do
30
+ subject { described_class.new(data).starting_at }
31
+
32
+ it 'should be a time' do
33
+ subject.must_be_instance_of(Time)
34
+ end
35
+ end
36
+
37
+ describe '#variant' do
38
+ subject { described_class.new(data).variant }
39
+
40
+ describe 'has "ad" => true' do
41
+ let(:data) { random_performance.merge('ad' => true) }
42
+
43
+ it 'includes "audio_described"' do
44
+ subject.must_include('audio_described')
45
+ end
46
+ end
47
+
48
+ describe 'has "ss" => true' do
49
+ let(:data) { random_performance.merge('subtitled' => true) }
50
+
51
+ it 'includes "subtitled"' do
52
+ subject.must_include('subtitled')
53
+ end
54
+ end
55
+ end
56
+
57
+ private
58
+
59
+ def random_performance
60
+ JSON.parse(performances_tomorrow_json(3))['performances'].sample
61
+ end
62
+ end
@@ -50,7 +50,7 @@ describe CineworldUk::Internal::TitleSanitizer do
50
50
  let(:title) { 'Bolshoi Ballet: The Legend of Love' }
51
51
 
52
52
  it 'removes prefix' do
53
- subject.must_equal('Bolshoi: The Legend of Love')
53
+ subject.must_equal('Bolshoi Ballet: The Legend of Love')
54
54
  end
55
55
  end
56
56
 
@@ -1,38 +1,45 @@
1
1
  require_relative '../../test_helper'
2
+ require_relative '../../support/fixture_reader'
2
3
 
3
- describe CineworldUk::Screening do
4
- let(:website) { Minitest::Mock.new }
4
+ describe CineworldUk::Performance do
5
+ include Support::FixtureReader
5
6
 
6
- before do
7
- WebMock.disable_net_connect!
8
- end
7
+ let(:described_class) { CineworldUk::Performance }
8
+ let(:api_response) { Minitest::Mock.new }
9
+
10
+ before { WebMock.disable_net_connect! }
9
11
 
10
12
  describe '.at(cinema_id)' do
11
- subject { CineworldUk::Screening.at(3) }
13
+ subject { described_class.at(3) }
12
14
 
13
15
  before do
14
- website.expect(:whatson, whatson_html('brighton'), [3])
15
- website.expect(:cinemas, cinemas_html)
16
+ api_response.expect(:cinema_list, cinema_list_json)
17
+ api_response.expect(:film_list, film_list_json)
18
+ api_response.expect(:film_list_comingsoon, film_list_comingsoon_json)
19
+ api_response.expect(:dates, fake_dates_tomorrow_json, [3])
20
+ api_response.expect(:performances,
21
+ performances_tomorrow_json(3),
22
+ [3, Date.today + 1])
16
23
  end
17
24
 
18
- it 'returns an array of screenings' do
19
- CineworldUk::Internal::Website.stub :new, website do
25
+ it 'returns an array of performances' do
26
+ CineworldUk::Internal::ApiResponse.stub :new, api_response do
20
27
  subject.must_be_instance_of(Array)
21
- subject.each do |screening|
22
- screening.must_be_instance_of(CineworldUk::Screening)
28
+ subject.each do |performance|
29
+ performance.must_be_instance_of(described_class)
23
30
  end
24
31
  end
25
32
  end
26
33
 
27
- it 'returns correct number of screenings' do
28
- CineworldUk::Internal::Website.stub :new, website do
29
- subject.count.must_equal 217
34
+ it 'returns at least a sensible number' do
35
+ CineworldUk::Internal::ApiResponse.stub :new, api_response do
36
+ subject.count.must_be :>, 5
30
37
  end
31
38
  end
32
39
  end
33
40
 
34
41
  describe '.new' do
35
- subject { CineworldUk::Screening.new(options) }
42
+ subject { described_class.new(options) }
36
43
 
37
44
  describe 'simple' do
38
45
  let(:options) do
@@ -40,7 +47,7 @@ describe CineworldUk::Screening do
40
47
  film_name: 'Iron Man 3',
41
48
  cinema_id: 3,
42
49
  cinema_name: 'Cineworld Brighton',
43
- time: Time.utc(2013, 9, 12, 11, 0)
50
+ starting_at: Time.utc(2013, 9, 12, 11, 0)
44
51
  }
45
52
  end
46
53
 
@@ -64,11 +71,11 @@ describe CineworldUk::Screening do
64
71
  dimension: '3d',
65
72
  cinema_id: 3,
66
73
  cinema_name: 'Cineworld Brighton',
67
- time: Time.utc(2013, 9, 12, 11, 0)
74
+ starting_at: Time.utc(2013, 9, 12, 11, 0)
68
75
  }
69
76
  end
70
77
 
71
- subject { CineworldUk::Screening.new(options).dimension }
78
+ subject { described_class.new(options).dimension }
72
79
 
73
80
  it 'returns 2d or 3d' do
74
81
  subject.must_be_instance_of(String)
@@ -76,8 +83,8 @@ describe CineworldUk::Screening do
76
83
  end
77
84
  end
78
85
 
79
- describe '#showing_at' do
80
- subject { CineworldUk::Screening.new(options).showing_at }
86
+ describe '#starting_at' do
87
+ subject { described_class.new(options).starting_at }
81
88
 
82
89
  describe 'with utc time' do
83
90
  let(:options) do
@@ -85,7 +92,7 @@ describe CineworldUk::Screening do
85
92
  film_name: 'Iron Man 3',
86
93
  cinema_id: 3,
87
94
  cinema_name: 'Cineworld Brighton',
88
- time: Time.utc(2013, 9, 12, 11, 0)
95
+ starting_at: Time.utc(2013, 9, 12, 11, 0)
89
96
  }
90
97
  end
91
98
 
@@ -101,13 +108,14 @@ describe CineworldUk::Screening do
101
108
  film_name: 'Iron Man 3',
102
109
  cinema_id: 3,
103
110
  cinema_name: 'Cineworld Brighton',
104
- time: Time.parse('2013-09-12 11:00')
111
+ starting_at: Time.new(2013, 9, 12, 11, 0)
105
112
  }
106
113
  end
107
114
 
108
115
  it 'returns UTC time' do
109
116
  subject.must_be_instance_of Time
110
117
  subject.must_equal Time.utc(2013, 9, 12, 10, 0)
118
+ subject.utc?.must_equal(true)
111
119
  end
112
120
  end
113
121
  end
@@ -118,11 +126,11 @@ describe CineworldUk::Screening do
118
126
  film_name: 'Iron Man 3',
119
127
  cinema_id: 3,
120
128
  cinema_name: 'Cineworld Brighton',
121
- time: Time.utc(2013, 9, 12, 11, 0)
129
+ starting_at: Time.utc(2013, 9, 12, 11, 0)
122
130
  }
123
131
  end
124
132
 
125
- subject { CineworldUk::Screening.new(options).showing_on }
133
+ subject { described_class.new(options).showing_on }
126
134
 
127
135
  it 'returns date of showing' do
128
136
  subject.must_be_instance_of(Date)
@@ -131,42 +139,22 @@ describe CineworldUk::Screening do
131
139
  end
132
140
 
133
141
  describe '#variant' do
134
- subject { CineworldUk::Screening.new(options).variant }
142
+ subject { described_class.new(options).variant }
135
143
 
136
144
  let(:options) do
137
145
  {
138
146
  film_name: 'Iron Man 3',
139
147
  cinema_id: 3,
140
148
  cinema_name: 'Cineworld Brighton',
141
- time: Time.utc(2013, 9, 12, 11, 0),
149
+ starting_at: Time.utc(2013, 9, 12, 11, 0),
142
150
  variant: ['Kids']
143
151
  }
144
152
  end
145
153
 
146
154
  it 'is an alphabetically ordered array of lower-cased strings' do
147
155
  subject.must_be_instance_of Array
148
- subject.each do |tag|
149
- tag.must_be_instance_of String
150
- end
156
+ subject.each { |element| element.must_be_instance_of String }
151
157
  subject.must_equal %w(kids)
152
158
  end
153
159
  end
154
-
155
- private
156
-
157
- def cinemas_html
158
- read_file('../../../fixtures/cinemas.html')
159
- end
160
-
161
- def information_html(filename)
162
- read_file("../../../fixtures/information/#{filename}.html")
163
- end
164
-
165
- def read_file(filepath)
166
- File.read(File.expand_path(filepath, __FILE__))
167
- end
168
-
169
- def whatson_html(filename)
170
- read_file("../../../fixtures/whatson/#{filename}.html")
171
- end
172
160
  end
@@ -0,0 +1,44 @@
1
+ module Support
2
+ # Read fixture files from disk, for test support
3
+ module FixtureReader
4
+ private
5
+
6
+ FIXTURE_PATH = '../../fixtures/api'
7
+
8
+ def cinema_list_json
9
+ read_file("#{FIXTURE_PATH}/cinema-list.json")
10
+ end
11
+
12
+ def cinema_detail_json(num)
13
+ read_file("#{FIXTURE_PATH}/cinema-detail-#{num}.json")
14
+ end
15
+
16
+ def dates_json(num)
17
+ read_file("#{FIXTURE_PATH}/dates-#{num}.json")
18
+ end
19
+
20
+ def fake_dates_tomorrow_json
21
+ { "dates": [tomorrow_s] }.to_json
22
+ end
23
+
24
+ def film_list_comingsoon_json
25
+ read_file("#{FIXTURE_PATH}/film-list-comingsoon.json")
26
+ end
27
+
28
+ def film_list_json
29
+ read_file("#{FIXTURE_PATH}/film-list.json")
30
+ end
31
+
32
+ def performances_tomorrow_json(num)
33
+ read_file("#{FIXTURE_PATH}/performances-tomorrow-#{num}.json")
34
+ end
35
+
36
+ def read_file(filepath)
37
+ File.read(File.expand_path(filepath, __FILE__))
38
+ end
39
+
40
+ def tomorrow_s
41
+ (Date.today + 1).strftime('%Y%m%d')
42
+ end
43
+ end
44
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cineworld_uk
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.6
4
+ version: 3.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andy Croll
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-06 00:00:00.000000000 Z
11
+ date: 2016-02-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -67,35 +67,21 @@ dependencies:
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: nokogiri
70
+ name: cinebase
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ">="
74
- - !ruby/object:Gem::Version
75
- version: '0'
76
- type: :runtime
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: '0'
83
- - !ruby/object:Gem::Dependency
84
- name: tzinfo
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ">="
73
+ - - "~>"
88
74
  - !ruby/object:Gem::Version
89
- version: '0'
75
+ version: 3.0.0
90
76
  type: :runtime
91
77
  prerelease: false
92
78
  version_requirements: !ruby/object:Gem::Requirement
93
79
  requirements:
94
- - - ">="
80
+ - - "~>"
95
81
  - !ruby/object:Gem::Version
96
- version: '0'
82
+ version: 3.0.0
97
83
  - !ruby/object:Gem::Dependency
98
- name: tzinfo-data
84
+ name: nokogiri
99
85
  requirement: !ruby/object:Gem::Requirement
100
86
  requirements:
101
87
  - - ">="
@@ -125,32 +111,34 @@ files:
125
111
  - cineworld_uk.gemspec
126
112
  - lib/cineworld_uk.rb
127
113
  - lib/cineworld_uk/cinema.rb
128
- - lib/cineworld_uk/film.rb
129
- - lib/cineworld_uk/internal/film_with_screenings_parser.rb
130
- - lib/cineworld_uk/internal/screening_parser.rb
114
+ - lib/cineworld_uk/internal/api_response.rb
115
+ - lib/cineworld_uk/internal/parser/api/cinema_address.rb
116
+ - lib/cineworld_uk/internal/parser/api/film.rb
117
+ - lib/cineworld_uk/internal/parser/api/film_lookup.rb
118
+ - lib/cineworld_uk/internal/parser/api/performance.rb
119
+ - lib/cineworld_uk/internal/parser/api/performances_by_day.rb
131
120
  - lib/cineworld_uk/internal/title_sanitizer.rb
132
- - lib/cineworld_uk/internal/website.rb
133
- - lib/cineworld_uk/internal/whatson_parser.rb
134
- - lib/cineworld_uk/screening.rb
121
+ - lib/cineworld_uk/performance.rb
135
122
  - lib/cineworld_uk/version.rb
136
- - test/fixture_updater.rb
137
- - test/fixtures/cinemas.html
138
- - test/fixtures/information/brighton.html
139
- - test/fixtures/information/bristol.html
140
- - test/fixtures/whatson/brighton.html
141
- - test/fixtures/whatson/brighton/film_first.html
142
- - test/fixtures/whatson/brighton/film_last.html
143
- - test/fixtures/whatson/brighton/film_second.html
144
- - test/fixtures/whatson/glasgow-imax-at-gsc/film_first.html
145
- - test/fixtures/whatson/the-o2-greenwich/film_first.html
123
+ - test/fixtures/api/cinema-detail-10.json
124
+ - test/fixtures/api/cinema-detail-21.json
125
+ - test/fixtures/api/cinema-detail-3.json
126
+ - test/fixtures/api/cinema-detail-96.json
127
+ - test/fixtures/api/cinema-list.json
128
+ - test/fixtures/api/dates-3.json
129
+ - test/fixtures/api/film-list-comingsoon.json
130
+ - test/fixtures/api/film-list.json
131
+ - test/fixtures/api/performances-tomorrow-3.json
146
132
  - test/lib/cineworld_uk/cinema_test.rb
147
- - test/lib/cineworld_uk/film_test.rb
148
- - test/lib/cineworld_uk/internal/film_with_screenings_parser_test.rb
133
+ - test/lib/cineworld_uk/internal/api_response_test.rb
134
+ - test/lib/cineworld_uk/internal/parser/api/cinema_address_test.rb
135
+ - test/lib/cineworld_uk/internal/parser/api/film_lookup_test.rb
136
+ - test/lib/cineworld_uk/internal/parser/api/film_test.rb
137
+ - test/lib/cineworld_uk/internal/parser/api/performance_test.rb
149
138
  - test/lib/cineworld_uk/internal/title_sanitizer_test.rb
150
- - test/lib/cineworld_uk/internal/website_test.rb
151
- - test/lib/cineworld_uk/internal/whatson_parser_test.rb
152
- - test/lib/cineworld_uk/screening_test.rb
139
+ - test/lib/cineworld_uk/performance_test.rb
153
140
  - test/lib/cineworld_uk/version_test.rb
141
+ - test/support/fixture_reader.rb
154
142
  - test/test_helper.rb
155
143
  homepage: https://github.com/andycroll/cineworld_uk
156
144
  licenses:
@@ -172,28 +160,29 @@ required_rubygems_version: !ruby/object:Gem::Requirement
172
160
  version: '0'
173
161
  requirements: []
174
162
  rubyforge_project:
175
- rubygems_version: 2.2.2
163
+ rubygems_version: 2.4.5
176
164
  signing_key:
177
165
  specification_version: 4
178
166
  summary: Parses cinema and showing data from the cineworld.co.uk website
179
167
  test_files:
180
- - test/fixture_updater.rb
181
- - test/fixtures/cinemas.html
182
- - test/fixtures/information/brighton.html
183
- - test/fixtures/information/bristol.html
184
- - test/fixtures/whatson/brighton.html
185
- - test/fixtures/whatson/brighton/film_first.html
186
- - test/fixtures/whatson/brighton/film_last.html
187
- - test/fixtures/whatson/brighton/film_second.html
188
- - test/fixtures/whatson/glasgow-imax-at-gsc/film_first.html
189
- - test/fixtures/whatson/the-o2-greenwich/film_first.html
168
+ - test/fixtures/api/cinema-detail-10.json
169
+ - test/fixtures/api/cinema-detail-21.json
170
+ - test/fixtures/api/cinema-detail-3.json
171
+ - test/fixtures/api/cinema-detail-96.json
172
+ - test/fixtures/api/cinema-list.json
173
+ - test/fixtures/api/dates-3.json
174
+ - test/fixtures/api/film-list-comingsoon.json
175
+ - test/fixtures/api/film-list.json
176
+ - test/fixtures/api/performances-tomorrow-3.json
190
177
  - test/lib/cineworld_uk/cinema_test.rb
191
- - test/lib/cineworld_uk/film_test.rb
192
- - test/lib/cineworld_uk/internal/film_with_screenings_parser_test.rb
178
+ - test/lib/cineworld_uk/internal/api_response_test.rb
179
+ - test/lib/cineworld_uk/internal/parser/api/cinema_address_test.rb
180
+ - test/lib/cineworld_uk/internal/parser/api/film_lookup_test.rb
181
+ - test/lib/cineworld_uk/internal/parser/api/film_test.rb
182
+ - test/lib/cineworld_uk/internal/parser/api/performance_test.rb
193
183
  - test/lib/cineworld_uk/internal/title_sanitizer_test.rb
194
- - test/lib/cineworld_uk/internal/website_test.rb
195
- - test/lib/cineworld_uk/internal/whatson_parser_test.rb
196
- - test/lib/cineworld_uk/screening_test.rb
184
+ - test/lib/cineworld_uk/performance_test.rb
197
185
  - test/lib/cineworld_uk/version_test.rb
186
+ - test/support/fixture_reader.rb
198
187
  - test/test_helper.rb
199
188
  has_rdoc: