spacex 1.0.2 → 2.0.0
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 +5 -5
- data/.github/workflows/ruby.yml +26 -0
- data/.gitignore +1 -0
- data/.rubocop.yml +6 -0
- data/.rubocop_todo.yml +1 -1
- data/CHANGELOG.md +54 -1
- data/CLAUDE.md +55 -0
- data/Dangerfile +28 -0
- data/Gemfile +12 -1
- data/README.md +52 -510
- data/docs/v3.md +525 -0
- data/docs/v4.md +179 -0
- data/lib/spacex/base_request.rb +8 -8
- data/lib/spacex/capsules.rb +10 -12
- data/lib/spacex/company.rb +7 -0
- data/lib/spacex/cores.rb +11 -14
- data/lib/spacex/crew.rb +15 -0
- data/lib/spacex/{dragon_capsules.rb → dragons.rb} +14 -16
- data/lib/spacex/history.rb +9 -2
- data/lib/spacex/landpads.rb +23 -0
- data/lib/spacex/launches.rb +35 -11
- data/lib/spacex/launchpads.rb +23 -0
- data/lib/spacex/models.rb +16 -0
- data/lib/spacex/payloads.rb +31 -2
- data/lib/spacex/rockets.rb +26 -3
- data/lib/spacex/ships.rb +22 -24
- data/lib/spacex/starlink.rb +16 -0
- data/lib/spacex/version.rb +1 -1
- data/lib/spacex.rb +2 -17
- data/spacex.gemspec +6 -9
- data/spec/coverage_helper.rb +5 -0
- data/spec/fixtures/spacex/v4/capsules/all.yml +122 -0
- data/spec/fixtures/spacex/v4/capsules/one.yml +89 -0
- data/spec/fixtures/spacex/v4/company.yml +80 -0
- data/spec/fixtures/spacex/v4/cores/all.yml +76 -0
- data/spec/fixtures/spacex/v4/cores/one.yml +75 -0
- data/spec/fixtures/spacex/v4/crew/all.yml +92 -0
- data/spec/fixtures/spacex/v4/crew/one.yml +74 -0
- data/spec/fixtures/spacex/v4/dragons/all.yml +101 -0
- data/spec/fixtures/spacex/v4/dragons/one.yml +189 -0
- data/spec/fixtures/spacex/v4/history/all.yml +85 -0
- data/spec/fixtures/spacex/v4/history/one.yml +168 -0
- data/spec/fixtures/spacex/v4/landpads/all.yml +85 -0
- data/spec/fixtures/spacex/v4/landpads/one.yml +172 -0
- data/spec/fixtures/spacex/v4/launches/all.yml +85 -0
- data/spec/fixtures/spacex/v4/launches/latest.yml +84 -0
- data/spec/fixtures/spacex/v4/launches/next.yml +84 -0
- data/spec/fixtures/spacex/v4/launches/one.yml +167 -0
- data/spec/fixtures/spacex/v4/launches/past.yml +85 -0
- data/spec/fixtures/spacex/v4/launches/upcoming.yml +97 -0
- data/spec/fixtures/spacex/v4/launchpads/all.yml +139 -0
- data/spec/fixtures/spacex/v4/launchpads/one.yml +225 -0
- data/spec/fixtures/spacex/v4/payloads/all.yml +85 -0
- data/spec/fixtures/spacex/v4/payloads/one.yml +167 -0
- data/spec/fixtures/spacex/v4/roadster.yml +90 -0
- data/spec/fixtures/spacex/v4/rockets/all.yml +76 -0
- data/spec/fixtures/spacex/v4/rockets/one.yml +84 -0
- data/spec/fixtures/spacex/v4/ships/all.yml +164 -0
- data/spec/fixtures/spacex/v4/ships/one.yml +248 -0
- data/spec/fixtures/spacex/v4/starlink/all.yml +17713 -0
- data/spec/fixtures/spacex/v4/starlink/one.yml +17798 -0
- data/spec/spacex/base_request_spec.rb +112 -0
- data/spec/spacex/capsules_spec.rb +19 -28
- data/spec/spacex/company_spec.rb +26 -0
- data/spec/spacex/cores_spec.rb +18 -31
- data/spec/spacex/crew_spec.rb +27 -0
- data/spec/spacex/dragons_spec.rb +39 -0
- data/spec/spacex/history_spec.rb +16 -40
- data/spec/spacex/landpads_spec.rb +35 -0
- data/spec/spacex/launches_spec.rb +28 -628
- data/spec/spacex/launchpads_spec.rb +34 -0
- data/spec/spacex/payloads_spec.rb +27 -51
- data/spec/spacex/roadster_spec.rb +5 -29
- data/spec/spacex/rockets_spec.rb +26 -194
- data/spec/spacex/ships_spec.rb +20 -51
- data/spec/spacex/starlink_spec.rb +28 -0
- data/spec/spacex/version_spec.rb +12 -0
- data/spec/spec_helper.rb +3 -9
- metadata +106 -137
- data/.ruby-version +0 -1
- data/.travis.yml +0 -21
- data/lib/spacex/api_info.rb +0 -7
- data/lib/spacex/company_info.rb +0 -7
- data/lib/spacex/endpoint.rb +0 -3
- data/lib/spacex/landing_pads.rb +0 -11
- data/lib/spacex/launch_pads.rb +0 -11
- data/lib/spacex/missions.rb +0 -18
- data/spec/fixtures/spacex/api_info/info.yml +0 -65
- data/spec/fixtures/spacex/capsules/C202.yml +0 -123
- data/spec/fixtures/spacex/capsules.yml +0 -83
- data/spec/fixtures/spacex/company_info/info.yml +0 -129
- data/spec/fixtures/spacex/cores/B1041.yml +0 -123
- data/spec/fixtures/spacex/cores.yml +0 -62
- data/spec/fixtures/spacex/dragon_capsules/info/dragon1.yml +0 -131
- data/spec/fixtures/spacex/dragon_capsules/info.yml +0 -77
- data/spec/fixtures/spacex/history/info/4.yml +0 -62
- data/spec/fixtures/spacex/history/info.yml +0 -62
- data/spec/fixtures/spacex/landing_pads/info/LZ-4.yml +0 -70
- data/spec/fixtures/spacex/landing_pads/info.yml +0 -68
- data/spec/fixtures/spacex/launch_pads/info/vafb_slc_4e.yml +0 -71
- data/spec/fixtures/spacex/launch_pads/info.yml +0 -104
- data/spec/fixtures/spacex/launches/68.yml +0 -69
- data/spec/fixtures/spacex/launches/all.yml +0 -62
- data/spec/fixtures/spacex/launches/info.yml +0 -62
- data/spec/fixtures/spacex/launches/latest.yml +0 -245
- data/spec/fixtures/spacex/launches/next.yml +0 -123
- data/spec/fixtures/spacex/launches/past.yml +0 -62
- data/spec/fixtures/spacex/launches/upcoming.yml +0 -64
- data/spec/fixtures/spacex/launches.yml +0 -62
- data/spec/fixtures/spacex/missions/F3364BF.yml +0 -157
- data/spec/fixtures/spacex/missions/info.yml +0 -62
- data/spec/fixtures/spacex/payloads/RatSat.yml +0 -62
- data/spec/fixtures/spacex/payloads/info.yml +0 -62
- data/spec/fixtures/spacex/roadster/info.yml +0 -133
- data/spec/fixtures/spacex/rockets/info/falcon1.yml +0 -139
- data/spec/fixtures/spacex/rockets/info/invalid.yml +0 -61
- data/spec/fixtures/spacex/rockets/info.yml +0 -105
- data/spec/fixtures/spacex/ships/info/AMERICANCHAMPION.yml +0 -125
- data/spec/fixtures/spacex/ships/info.yml +0 -139
- data/spec/spacex/api_info_spec.rb +0 -16
- data/spec/spacex/company_info_spec.rb +0 -27
- data/spec/spacex/dragon_capsules_spec.rb +0 -107
- data/spec/spacex/endpoint_spec.rb +0 -9
- data/spec/spacex/landing_pads_spec.rb +0 -72
- data/spec/spacex/launch_pads_spec.rb +0 -77
- data/spec/spacex/missions_spec.rb +0 -35
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
http_interactions:
|
|
3
|
-
- request:
|
|
4
|
-
method: get
|
|
5
|
-
uri: https://api.spacexdata.com/v3/ships/
|
|
6
|
-
body:
|
|
7
|
-
encoding: US-ASCII
|
|
8
|
-
string: ''
|
|
9
|
-
headers:
|
|
10
|
-
User-Agent:
|
|
11
|
-
- Faraday v0.15.3
|
|
12
|
-
Accept-Encoding:
|
|
13
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
14
|
-
Accept:
|
|
15
|
-
- "*/*"
|
|
16
|
-
response:
|
|
17
|
-
status:
|
|
18
|
-
code: 200
|
|
19
|
-
message: OK
|
|
20
|
-
headers:
|
|
21
|
-
Date:
|
|
22
|
-
- Mon, 15 Oct 2018 03:46:32 GMT
|
|
23
|
-
Content-Type:
|
|
24
|
-
- application/json; charset=utf-8
|
|
25
|
-
Transfer-Encoding:
|
|
26
|
-
- chunked
|
|
27
|
-
Connection:
|
|
28
|
-
- keep-alive
|
|
29
|
-
Set-Cookie:
|
|
30
|
-
- __cfduid=de80892177236026a57f27564aa9dfdaa1539575191; expires=Tue, 15-Oct-19
|
|
31
|
-
03:46:31 GMT; path=/; domain=.spacexdata.com; HttpOnly; Secure
|
|
32
|
-
Vary:
|
|
33
|
-
- Accept-Encoding, Origin
|
|
34
|
-
X-Dns-Prefetch-Control:
|
|
35
|
-
- 'off'
|
|
36
|
-
X-Frame-Options:
|
|
37
|
-
- SAMEORIGIN
|
|
38
|
-
Strict-Transport-Security:
|
|
39
|
-
- max-age=15552000; includeSubDomains
|
|
40
|
-
X-Download-Options:
|
|
41
|
-
- noopen
|
|
42
|
-
X-Content-Type-Options:
|
|
43
|
-
- nosniff
|
|
44
|
-
X-Xss-Protection:
|
|
45
|
-
- 1; mode=block
|
|
46
|
-
Access-Control-Allow-Origin:
|
|
47
|
-
- "*"
|
|
48
|
-
X-Response-Time:
|
|
49
|
-
- 79ms
|
|
50
|
-
Expect-Ct:
|
|
51
|
-
- max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
|
|
52
|
-
Server:
|
|
53
|
-
- cloudflare
|
|
54
|
-
Cf-Ray:
|
|
55
|
-
- 469f4c957a655747-IAD
|
|
56
|
-
body:
|
|
57
|
-
encoding: ASCII-8BIT
|
|
58
|
-
string: '[{"ship_id":"AMERICANCHAMPION","ship_name":"American Champion","ship_model":null,"ship_type":"Tug","roles":["Support
|
|
59
|
-
Ship","Barge Tug"],"active":false,"imo":7434016,"mmsi":367020820,"abs":571252,"class":7604342,"weight_lbs":588000,"weight_kg":266712,"year_built":1976,"home_port":"Port
|
|
60
|
-
of Los Angeles","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":30.5276,"longitude":-88.10261},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"COTS
|
|
61
|
-
1","flight":7},{"name":"COTS 2","flight":8}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:434663/vessel:AMERICAN%20CHAMPION","image":"https://i.imgur.com/woCxpkj.jpg"},{"ship_id":"AMERICANISLANDER","ship_name":"American
|
|
62
|
-
Islander","ship_model":null,"ship_type":"Cargo","roles":["Dragon Recovery"],"active":false,"imo":null,"mmsi":367035570,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":null,"home_port":"Port
|
|
63
|
-
of Los Angeles","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":33.73421,"longitude":-118.2635},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CRS-1","flight":9},{"name":"CRS-2","flight":10},{"name":"CRS-3","flight":14},{"name":"CRS-4","flight":18}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:435112/vessel:AMERICAN%20ISLANDER","image":"https://i.imgur.com/jmj8Sh2.jpg"},{"ship_id":"AMERICANSPIRIT","ship_name":"American
|
|
64
|
-
Spirit","ship_model":null,"ship_type":"Cargo","roles":["Support Ship"],"active":false,"imo":null,"mmsi":null,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":null,"home_port":"Port
|
|
65
|
-
of Los Angeles","status":null,"speed_kn":null,"course_deg":null,"position":{"latitude":null,"longitude":null},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CASSIOPE","flight":11}],"url":null,"image":null},{"ship_id":"ASOG","ship_name":"A
|
|
66
|
-
Shortfall of Gravitas","ship_model":null,"ship_type":"Barge","roles":["ASDS
|
|
67
|
-
barge"],"active":false,"imo":null,"abs":null,"mmsi":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":null,"home_port":"Port
|
|
68
|
-
Canaveral","status":null,"speed_kn":null,"course_deg":null,"position":{"latitude":null,"longitude":null},"successful_landings":null,"attempted_landings":null,"missions":[],"url":null,"image":null},{"ship_id":"BETTYRGAMBARELLA","ship_name":"Betty
|
|
69
|
-
R Gambarella","ship_model":null,"ship_type":"Tug","roles":["ASDS Tug"],"active":false,"imo":7517478,"mmsi":368000890,"abs":562590,"class":7427463,"weight_lbs":446000,"weight_kg":202302,"year_built":1974,"home_port":"Port
|
|
70
|
-
of Los Angeles","status":"Towing Astern","speed_kn":0,"course_deg":null,"position":{"latitude":33.77161,"longitude":-118.2121},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"FormoSat-5","flight":46},{"name":"Iridium
|
|
71
|
-
NEXT Mission 3","flight":48}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:428415/vessel:BETTY%20R%20GAMBARELLA","image":"https://i.imgur.com/ngYgFnn.jpg"},{"ship_id":"ELSBETH3","ship_name":"Elsbeth
|
|
72
|
-
III","ship_model":null,"ship_type":"Tug","roles":["ASDS Tug"],"active":false,"imo":8983375,"mmsi":367017460,"abs":null,"class":null,"weight_lbs":602000,"weight_kg":273063,"year_built":1999,"home_port":"Port
|
|
73
|
-
Canaveral","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":29.6608,"longitude":-91.09957},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CRS-5","flight":19},{"name":"DSCOVR","flight":20},{"name":"CRS-6","flight":22},{"name":"CRS-7","flight":24},{"name":"SES-9","flight":27},{"name":"CRS-8","flight":28},{"name":"JCSAT-2B","flight":29},{"name":"Thaicom
|
|
74
|
-
8","flight":30},{"name":"ABS-2A / Eutelsat 117W B","flight":31},{"name":"CRS-9","flight":32},{"name":"JCSAT-16","flight":33},{"name":"SES-10","flight":38},{"name":"BulgariaSat-1","flight":42},{"name":"Boeing
|
|
75
|
-
X-37B OTV 5","flight":47}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:434560/vessel:ELSBETH%20III","image":"https://i.imgur.com/1s5DUbJ.jpg"},{"ship_id":"GONAVIGATOR","ship_name":"GO
|
|
76
|
-
Navigator","ship_model":null,"ship_type":"Cargo","roles":["Support Ship","Fairing
|
|
77
|
-
Recovery"],"active":true,"imo":9566887,"mmsi":367550000,"abs":1221524,"class":9204358,"weight_lbs":996000,"weight_kg":451778,"year_built":2009,"home_port":"Port
|
|
78
|
-
Canaveral","status":"Moored","speed_kn":0,"course_deg":null,"position":{"latitude":28.41315,"longitude":-80.62064},"successful_landings":null,"attempted_landings":null,"missions":[],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:452540/vessel:GO%20NAVIGATOR","image":"https://i.imgur.com/MjNWzhO.jpg"},{"ship_id":"GOPURSUIT","ship_name":"GO
|
|
79
|
-
Pursuit","ship_model":null,"ship_type":"Cargo","roles":["Support Ship","Fairing
|
|
80
|
-
Recovery"],"active":false,"imo":9458884,"mmsi":367191410,"abs":1201189,"class":7174230,"weight_lbs":1108925,"weight_kg":502999,"year_built":2007,"home_port":"Port
|
|
81
|
-
Canaveral","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":29.11541,"longitude":-90.20965},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"TESS","flight":60},{"name":"Bangabandhu-1","flight":61},{"name":"SES-12","flight":63},{"name":"Telstar
|
|
82
|
-
19V","flight":65}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:439594/vessel:GO%20PURSUIT","image":"https://i.imgur.com/5w1ZWre.jpg"},{"ship_id":"GOQUEST","ship_name":"GO
|
|
83
|
-
Quest","ship_model":null,"ship_type":"Cargo","roles":["Support Ship"],"active":true,"imo":1155515,"mmsi":367564890,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":2014,"home_port":"Port
|
|
84
|
-
Canaveral","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":28.40891,"longitude":-80.61788},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CRS-5","flight":19},{"name":"DSCOVR","flight":20},{"name":"CRS-6","flight":22},{"name":"CRS-7","flight":24},{"name":"SES-9","flight":27},{"name":"CRS-8","flight":28},{"name":"JCSAT-2B","flight":29},{"name":"Thaicom
|
|
85
|
-
8","flight":30},{"name":"ABS-2A / Eutelsat 117W B","flight":31},{"name":"CRS-9","flight":32},{"name":"JCSAT-16","flight":33},{"name":"SES-10","flight":38},{"name":"BulgariaSat-1","flight":42},{"name":"Boeing
|
|
86
|
-
X-37B OTV 5","flight":47},{"name":"SES-11 / Echostar 105","flight":49},{"name":"SES-16
|
|
87
|
-
/ GovSat-1","flight":54},{"name":"TESS","flight":60},{"name":"Bangabandhu-1","flight":61},{"name":"Telstar
|
|
88
|
-
19V","flight":65},{"name":"Telstar 18V","flight":68}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:450521/vessel:GO%20QUEST","image":"https://i.imgur.com/ABXtHKa.jpg"},{"ship_id":"GOSEARCHER","ship_name":"GO
|
|
89
|
-
Searcher","ship_model":null,"ship_type":"Cargo","roles":["Support Ship","Fairing
|
|
90
|
-
Recovery"],"active":true,"imo":9591648,"mmsi":366584000,"abs":1226876,"class":10204360,"weight_lbs":994000,"weight_kg":450870,"year_built":2010,"home_port":"Port
|
|
91
|
-
Canaveral","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":28.41313,"longitude":-80.62058},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CRS-5","flight":19},{"name":"DSCOVR","flight":20},{"name":"CRS-6","flight":22},{"name":"CRS-7","flight":24},{"name":"SES-9","flight":27},{"name":"CRS-8","flight":28},{"name":"JCSAT-2B","flight":29},{"name":"Thaicom
|
|
92
|
-
8","flight":30},{"name":"ABS-2A / Eutelsat 117W B","flight":31},{"name":"CRS-9","flight":32},{"name":"JCSAT-16","flight":33},{"name":"SES-10","flight":38},{"name":"NROL-76","flight":39},{"name":"BulgariaSat-1","flight":42},{"name":"Falcon
|
|
93
|
-
Heavy Test Flight","flight":55}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:426008/vessel:GO%20SEARCHER","image":"https://i.imgur.com/X4YQJZf.jpg"},{"ship_id":"HAWK","ship_name":"HAWK","ship_model":null,"ship_type":"Tug","roles":["ASDS
|
|
94
|
-
Tug"],"active":true,"imo":9103295,"mmsi":366943250,"abs":1033239,"class":9523438,"weight_lbs":1120000,"weight_kg":508023,"year_built":1995,"home_port":"Port
|
|
95
|
-
Canaveral","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":26.08241,"longitude":-80.11564},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"SES-11
|
|
96
|
-
/ Echostar 105","flight":49},{"name":"KoreaSat 5A","flight":50},{"name":"Falcon
|
|
97
|
-
Heavy Test Flight","flight":55},{"name":"TESS","flight":60},{"name":"Telstar
|
|
98
|
-
19V","flight":65},{"name":"Merah Putih","flight":67},{"name":"Telstar 18V","flight":68}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:430027/vessel:HAWK","image":"https://i.imgur.com/hGWWupT.jpg"},{"ship_id":"JRTI-1","ship_name":"Just
|
|
99
|
-
Read The Instructions","ship_model":"Marmac 300","ship_type":"Barge","roles":["ASDS
|
|
100
|
-
barge"],"active":false,"imo":null,"mmsi":null,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":2014,"home_port":"Port
|
|
101
|
-
Canaveral","status":null,"speed_kn":null,"course_deg":null,"position":{"latitude":null,"longitude":null},"successful_landings":0,"attempted_landings":2,"missions":[{"name":"CRS-5","flight":19},{"name":"CRS-6","flight":22}],"url":null,"image":"https://i.imgur.com/RJPmP8G.jpg"},{"ship_id":"JRTI-2","ship_name":"Just
|
|
102
|
-
Read The Instructions","ship_model":"Marmac 303","ship_type":"Barge","roles":["ASDS
|
|
103
|
-
barge"],"active":true,"imo":null,"mmsi":null,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":2015,"home_port":"Port
|
|
104
|
-
of Los Angeles","status":null,"speed_kn":null,"course_deg":null,"position":{"latitude":null,"longitude":null},"successful_landings":5,"attempted_landings":6,"missions":[{"name":"Jason-3","flight":26},{"name":"Iridium
|
|
105
|
-
NEXT Mission 1","flight":35},{"name":"Iridium NEXT Mission 2","flight":43},{"name":"FormoSat-5","flight":46},{"name":"Iridium
|
|
106
|
-
NEXT Mission 3","flight":48},{"name":"Iridium Next Mission 7","flight":66}],"url":null,"image":"https://i.imgur.com/7VMC0Gn.jpg"},{"ship_id":"KELLYC","ship_name":"Kelly
|
|
107
|
-
C","ship_model":null,"ship_type":"Tug","roles":["ASDS Tug"],"active":false,"imo":null,"mmsi":367693690,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":null,"home_port":"Port
|
|
108
|
-
of Los Angeles","status":"Moored","speed_kn":0,"course_deg":null,"position":{"latitude":33.77168,"longitude":-118.2117},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"Iridium
|
|
109
|
-
NEXT Mission 2","flight":43}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:3718707/vessel:KELLY%20C","image":null},{"ship_id":"MRSTEVEN","ship_name":"MR
|
|
110
|
-
STEVEN","ship_model":null,"ship_type":"High Speed Craft","roles":["Fairing
|
|
111
|
-
Recovery"],"active":true,"imo":9744465,"mmsi":338358000,"abs":1249191,"class":15252765,"weight_lbs":992000,"weight_kg":449964,"year_built":2015,"home_port":"Port
|
|
112
|
-
of Los Angeles","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":33.73134,"longitude":-118.2712},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"KoreaSat
|
|
113
|
-
5A","flight":50},{"name":"Paz / Starlink Demo","flight":56},{"name":"Iridium
|
|
114
|
-
NEXT Mission 4","flight":52},{"name":"Iridium NEXT Mission 6","flight":62},{"name":"Iridium
|
|
115
|
-
Next Mission 7","flight":66}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:3439091/vessel:MR%20STEVEN","image":"https://i.imgur.com/MtEgYbY.jpg"},{"ship_id":"NRCQUEST","ship_name":"NRC
|
|
116
|
-
Quest","ship_model":null,"ship_type":"Cargo","roles":["Support Ship","Dragon
|
|
117
|
-
Recovery"],"active":true,"imo":9271195,"mmsi":367486370,"abs":1134613,"class":2115909,"weight_lbs":972000,"weight_kg":440892,"year_built":2002,"home_port":"Port
|
|
118
|
-
of Los Angeles","status":"Moored","speed_kn":0,"course_deg":null,"position":{"latitude":33.72065,"longitude":-118.2744},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"CRS-5","flight":19},{"name":"CRS-6","flight":22},{"name":"Jason-3","flight":26},{"name":"CRS-8","flight":28},{"name":"CRS-9","flight":32},{"name":"Iridium
|
|
119
|
-
NEXT Mission 1","flight":35},{"name":"CRS-10","flight":36},{"name":"Iridium
|
|
120
|
-
NEXT Mission 2","flight":43},{"name":"CRS-11","flight":41},{"name":"CRS-12","flight":45},{"name":"CRS-13","flight":51},{"name":"CRS-14","flight":59},{"name":"Iridium
|
|
121
|
-
Next Mission 7","flight":66},{"name":"CRS-15","flight":64}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:447294/vessel:NRC%20QUEST","image":"https://i.imgur.com/GvtuYUN.jpg"},{"ship_id":"OCISLY","ship_name":"Of
|
|
122
|
-
Course I Still Love You","ship_model":"Marmac 304","ship_type":"Barge","roles":["ASDS
|
|
123
|
-
barge"],"active":true,"imo":null,"mmsi":null,"abs":null,"class":null,"weight_lbs":null,"weight_kg":null,"year_built":2015,"home_port":"Port
|
|
124
|
-
Canaveral","status":null,"speed_kn":null,"course_deg":null,"position":{"latitude":null,"longitude":null},"successful_landings":13,"attempted_landings":16,"missions":[{"name":"SES-9","flight":27},{"name":"CRS-8","flight":28},{"name":"JCSAT-2B","flight":29},{"name":"Thaicom
|
|
125
|
-
8","flight":30},{"name":"ABS-2A / Eutelsat 117W B","flight":31},{"name":"JCSAT-16","flight":33},{"name":"SES-10","flight":38},{"name":"BulgariaSat-1","flight":42},{"name":"SES-11
|
|
126
|
-
/ Echostar 105","flight":49},{"name":"KoreaSat 5A","flight":50},{"name":"Falcon
|
|
127
|
-
Heavy Test Flight","flight":55},{"name":"TESS","flight":60},{"name":"Bangabandhu-1","flight":61},{"name":"Telstar
|
|
128
|
-
19V","flight":65},{"name":"Merah Putih","flight":67},{"name":"Telstar 18V","flight":68}],"url":null,"image":"https://i.imgur.com/28dCx6G.jpg"},{"ship_id":"PACIFICFREEDOM","ship_name":"Pacific
|
|
129
|
-
Freeedom","ship_model":null,"ship_type":"Tug","roles":["ASDS Tug"],"active":true,"imo":null,"mmsi":367639830,"abs":570902,"class":7602544,"weight_lbs":198000,"weight_kg":89811,"year_built":1976,"home_port":"Port
|
|
130
|
-
of Los Angeles","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":32.69493,"longitude":-117.1509},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"Jason-3","flight":26},{"name":"Iridium
|
|
131
|
-
Next Mission 7","flight":66}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:4249791/vessel:PACIFIC%20FREEDOM","image":"https://i.imgur.com/eJWx70Z.jpg"},{"ship_id":"PACIFICWARRIOR","ship_name":"Pacific
|
|
132
|
-
Warrior","ship_model":null,"ship_type":"Tug","roles":["ASDS Tug"],"active":false,"imo":7641384,"mmsi":367008820,"abs":566282,"class":7434575,"weight_lbs":774000,"weight_kg":351080,"year_built":1974,"home_port":"Port
|
|
133
|
-
of Los Angeles","status":"Stopped","speed_kn":0,"course_deg":null,"position":{"latitude":37.77477,"longitude":-122.3837},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"Iridium
|
|
134
|
-
NEXT Mission 1","flight":35}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:434121/vessel:PACIFIC%20WARRIOR","image":"https://i.imgur.com/qdNDmYs.jpg"},{"ship_id":"RACHEL","ship_name":"RACHEL","ship_model":null,"ship_type":"Tug","roles":["ASDS
|
|
135
|
-
Tug"],"active":false,"imo":7600378,"mmsi":367488370,"abs":576417,"class":7611785,"weight_lbs":688000,"weight_kg":312072,"year_built":1976,"home_port":"Port
|
|
136
|
-
Canaveral","status":"Underway Using Engine","speed_kn":5.7,"course_deg":256,"position":{"latitude":29.67117,"longitude":-91.13429},"successful_landings":null,"attempted_landings":null,"missions":[{"name":"Bangabandhu-1","flight":61}],"url":"https://www.marinetraffic.com/en/ais/details/ships/shipid:447352/vessel:RACHEL","image":"https://i.imgur.com/IpYJWUW.jpg"}]'
|
|
137
|
-
http_version:
|
|
138
|
-
recorded_at: Mon, 15 Oct 2018 03:46:32 GMT
|
|
139
|
-
recorded_with: VCR 4.0.0
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::ApiInfo do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'api_info/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::ApiInfo.info
|
|
7
|
-
end
|
|
8
|
-
|
|
9
|
-
it 'returns API info' do
|
|
10
|
-
expect(subject.project_name).to eq 'SpaceX-API'
|
|
11
|
-
expect(subject.organization).to eq 'r/SpaceX'
|
|
12
|
-
expect(subject.organization_link).to eq 'https://github.com/r-spacex'
|
|
13
|
-
expect(subject.description).to eq 'Open Source REST API for rocket, core, capsule, pad, and launch data, created and maintained by the developers of the r/SpaceX organization'
|
|
14
|
-
end
|
|
15
|
-
end
|
|
16
|
-
end
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::CompanyInfo do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'company_info/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::CompanyInfo.info
|
|
7
|
-
end
|
|
8
|
-
it 'returns company info' do
|
|
9
|
-
expect(subject.name).to eq 'SpaceX'
|
|
10
|
-
expect(subject.founder).to eq 'Elon Musk'
|
|
11
|
-
expect(subject.founded).to eq 2002
|
|
12
|
-
expect(subject.employees).to eq 7000
|
|
13
|
-
expect(subject.vehicles).to eq 3
|
|
14
|
-
expect(subject.launche_sites).to eq nil
|
|
15
|
-
expect(subject.test_sites).to eq 1
|
|
16
|
-
expect(subject.ceo).to eq 'Elon Musk'
|
|
17
|
-
expect(subject.cto).to eq 'Elon Musk'
|
|
18
|
-
expect(subject.coo).to eq 'Gwynne Shotwell'
|
|
19
|
-
expect(subject.cto_propulsion).to eq 'Tom Mueller'
|
|
20
|
-
expect(subject.valuation).to eq 27_500_000_000
|
|
21
|
-
expect(subject.headquarters.address).to eq 'Rocket Road'
|
|
22
|
-
expect(subject.headquarters.city).to eq 'Hawthorne'
|
|
23
|
-
expect(subject.headquarters.state).to eq 'California'
|
|
24
|
-
expect(subject.summary).to eq 'SpaceX designs, manufactures and launches advanced rockets and spacecraft. The company was founded in 2002 to revolutionize space technology, with the ultimate goal of enabling people to live on other planets.'
|
|
25
|
-
end
|
|
26
|
-
end
|
|
27
|
-
end
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::DragonCapsules do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'dragon_capsules/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::DragonCapsules.info
|
|
7
|
-
end
|
|
8
|
-
it 'returns Dragon Capsules info' do
|
|
9
|
-
expect(subject.first.capsule_id).to eq 'dragon1'
|
|
10
|
-
expect(subject.first.name).to eq 'Dragon 1'
|
|
11
|
-
expect(subject.first.type).to eq 'capsule'
|
|
12
|
-
expect(subject.first.active).to eq true
|
|
13
|
-
expect(subject.first.crew_capacity).to eq 0
|
|
14
|
-
expect(subject.first.sidewall_angle_deg).to eq 15
|
|
15
|
-
expect(subject.first.orbit_duration_yr).to eq 2
|
|
16
|
-
expect(subject.first.dry_mass_kg).to eq 4_200
|
|
17
|
-
expect(subject.first.dry_mass_lb).to eq 9_300
|
|
18
|
-
expect(subject.first.first_flight).to eq '2010-12-08'
|
|
19
|
-
expect(subject.first.heat_shield).to eq ({ 'material' => 'PICA-X', 'size_meters' => 3.6, 'temp_degrees' => 3000, 'dev_partner' => 'NASA' })
|
|
20
|
-
expect(subject.first.heat_shield['material']).to eq 'PICA-X'
|
|
21
|
-
expect(subject.first.heat_shield['size_meters']).to eq 3.6
|
|
22
|
-
expect(subject.first.heat_shield['temp_degrees']).to eq 3_000
|
|
23
|
-
expect(subject.first.heat_shield['dev_partner']).to eq 'NASA'
|
|
24
|
-
expect(subject.first.thrusters[0]['type']).to eq 'Draco'
|
|
25
|
-
expect(subject.first.thrusters[0]['amount']).to eq 18
|
|
26
|
-
expect(subject.first.thrusters[0]['pods']).to eq 4
|
|
27
|
-
expect(subject.first.thrusters[0]['fuel_1']).to eq 'nitrogen tetroxide'
|
|
28
|
-
expect(subject.first.thrusters[0]['fuel_2']).to eq 'monomethylhydrazine'
|
|
29
|
-
expect(subject.first.thrusters[0]['thrust']['kN']).to eq 0.4
|
|
30
|
-
expect(subject.first.thrusters[0]['thrust']['lbf']).to eq 90
|
|
31
|
-
expect(subject.first.launch_payload_mass['kg']).to eq 6_000
|
|
32
|
-
expect(subject.first.launch_payload_mass['lb']).to eq 13_228
|
|
33
|
-
expect(subject.first.launch_payload_vol['cubic_meters']).to eq 25
|
|
34
|
-
expect(subject.first.launch_payload_vol['cubic_feet']).to eq 883
|
|
35
|
-
expect(subject.first.return_payload_mass['kg']).to eq 3_000
|
|
36
|
-
expect(subject.first.return_payload_mass['lb']).to eq 6_614
|
|
37
|
-
expect(subject.first.return_payload_vol['cubic_meters']).to eq 11
|
|
38
|
-
expect(subject.first.return_payload_vol['cubic_feet']).to eq 388
|
|
39
|
-
expect(subject.first.pressurized_capsule['payload_volume']['cubic_meters']).to eq 11
|
|
40
|
-
expect(subject.first.pressurized_capsule['payload_volume']['cubic_feet']).to eq 388
|
|
41
|
-
expect(subject.first.trunk['trunk_volume']['cubic_meters']).to eq 14
|
|
42
|
-
expect(subject.first.trunk['trunk_volume']['cubic_feet']).to eq 494
|
|
43
|
-
expect(subject.first.trunk['cargo']['solar_array']).to eq 2
|
|
44
|
-
expect(subject.first.trunk['cargo']['unpressurized_cargo']).to eq true
|
|
45
|
-
expect(subject.first.height_w_trunk['meters']).to eq 7.2
|
|
46
|
-
expect(subject.first.height_w_trunk['feet']).to eq 23.6
|
|
47
|
-
expect(subject.first.diameter['meters']).to eq 3.7
|
|
48
|
-
expect(subject.first.diameter['feet']).to eq 12
|
|
49
|
-
expect(subject.first.wikipedia).to eq 'https://en.wikipedia.org/wiki/SpaceX_Dragon'
|
|
50
|
-
expect(subject.first.description).to start_with 'Dragon is a reusable spacecraft developed'
|
|
51
|
-
|
|
52
|
-
expect(subject[1].capsule_id).to eq 'dragon2'
|
|
53
|
-
expect(subject[1].name).to eq 'Dragon 2'
|
|
54
|
-
end
|
|
55
|
-
end
|
|
56
|
-
|
|
57
|
-
context "#info('dragon1')", vcr: { cassette_name: 'dragon_capsules/info/dragon1' } do
|
|
58
|
-
subject do
|
|
59
|
-
SPACEX::DragonCapsules.info('dragon1')
|
|
60
|
-
end
|
|
61
|
-
|
|
62
|
-
it 'returns Dragon Capsule info for "dragon1"' do
|
|
63
|
-
expect(subject.capsule_id).to eq 'dragon1'
|
|
64
|
-
expect(subject.name).to eq 'Dragon 1'
|
|
65
|
-
expect(subject.type).to eq 'capsule'
|
|
66
|
-
expect(subject.active).to eq true
|
|
67
|
-
expect(subject.crew_capacity).to eq 0
|
|
68
|
-
expect(subject.sidewall_angle_deg).to eq 15
|
|
69
|
-
expect(subject.orbit_duration_yr).to eq 2
|
|
70
|
-
expect(subject.dry_mass_kg).to eq 4_200
|
|
71
|
-
expect(subject.dry_mass_lb).to eq 9_300
|
|
72
|
-
expect(subject.first_flight).to eq '2010-12-08'
|
|
73
|
-
expect(subject.heat_shield).to eq ({ 'material' => 'PICA-X', 'size_meters' => 3.6, 'temp_degrees' => 3000, 'dev_partner' => 'NASA' })
|
|
74
|
-
expect(subject.heat_shield['material']).to eq 'PICA-X'
|
|
75
|
-
expect(subject.heat_shield['size_meters']).to eq 3.6
|
|
76
|
-
expect(subject.heat_shield['temp_degrees']).to eq 3_000
|
|
77
|
-
expect(subject.heat_shield['dev_partner']).to eq 'NASA'
|
|
78
|
-
expect(subject.thrusters[0]['type']).to eq 'Draco'
|
|
79
|
-
expect(subject.thrusters[0]['amount']).to eq 18
|
|
80
|
-
expect(subject.thrusters[0]['pods']).to eq 4
|
|
81
|
-
expect(subject.thrusters[0]['fuel_1']).to eq 'nitrogen tetroxide'
|
|
82
|
-
expect(subject.thrusters[0]['fuel_2']).to eq 'monomethylhydrazine'
|
|
83
|
-
expect(subject.thrusters[0]['thrust']['kN']).to eq 0.4
|
|
84
|
-
expect(subject.thrusters[0]['thrust']['lbf']).to eq 90
|
|
85
|
-
expect(subject.launch_payload_mass['kg']).to eq 6_000
|
|
86
|
-
expect(subject.launch_payload_mass['lb']).to eq 13_228
|
|
87
|
-
expect(subject.launch_payload_vol['cubic_meters']).to eq 25
|
|
88
|
-
expect(subject.launch_payload_vol['cubic_feet']).to eq 883
|
|
89
|
-
expect(subject.return_payload_mass['kg']).to eq 3_000
|
|
90
|
-
expect(subject.return_payload_mass['lb']).to eq 6_614
|
|
91
|
-
expect(subject.return_payload_vol['cubic_meters']).to eq 11
|
|
92
|
-
expect(subject.return_payload_vol['cubic_feet']).to eq 388
|
|
93
|
-
expect(subject.pressurized_capsule['payload_volume']['cubic_meters']).to eq 11
|
|
94
|
-
expect(subject.pressurized_capsule['payload_volume']['cubic_feet']).to eq 388
|
|
95
|
-
expect(subject.trunk['trunk_volume']['cubic_meters']).to eq 14
|
|
96
|
-
expect(subject.trunk['trunk_volume']['cubic_feet']).to eq 494
|
|
97
|
-
expect(subject.trunk['cargo']['solar_array']).to eq 2
|
|
98
|
-
expect(subject.trunk['cargo']['unpressurized_cargo']).to eq true
|
|
99
|
-
expect(subject.height_w_trunk['meters']).to eq 7.2
|
|
100
|
-
expect(subject.height_w_trunk['feet']).to eq 23.6
|
|
101
|
-
expect(subject.diameter['meters']).to eq 3.7
|
|
102
|
-
expect(subject.diameter['feet']).to eq 12
|
|
103
|
-
expect(subject.wikipedia).to eq 'https://en.wikipedia.org/wiki/SpaceX_Dragon'
|
|
104
|
-
expect(subject.description).to start_with 'Dragon is a reusable spacecraft developed by Space'
|
|
105
|
-
end
|
|
106
|
-
end
|
|
107
|
-
end
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::LandingPads do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'landing_pads/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::LandingPads.info
|
|
7
|
-
end
|
|
8
|
-
|
|
9
|
-
it "returns all LandingPads' info when no id is passed" do
|
|
10
|
-
first_subject = subject.first
|
|
11
|
-
|
|
12
|
-
expect(subject.class).to eq Array
|
|
13
|
-
expect(first_subject.id).to eq 'LZ-1'
|
|
14
|
-
expect(first_subject.full_name).to eq 'Landing Zone 1'
|
|
15
|
-
expect(first_subject.status).to eq 'active'
|
|
16
|
-
expect(first_subject.location).to eq(
|
|
17
|
-
'name' => 'Cape Canaveral',
|
|
18
|
-
'region' => 'Florida',
|
|
19
|
-
'latitude' => 28.485833,
|
|
20
|
-
'longitude' => -80.544444
|
|
21
|
-
)
|
|
22
|
-
expect(first_subject.landing_type).to eq 'RTLS'
|
|
23
|
-
expect(first_subject.attempted_landings).to eq 14
|
|
24
|
-
expect(first_subject.successful_landings).to eq 13
|
|
25
|
-
expect(first_subject.wikipedia).to eq(
|
|
26
|
-
'https://en.wikipedia.org/wiki/Landing_Zones_1_and_2'
|
|
27
|
-
)
|
|
28
|
-
expect(first_subject.details).to eq(
|
|
29
|
-
"SpaceX's first east coast landing pad is Landing Zone 1, " \
|
|
30
|
-
'where the historic first Falcon 9 landing occurred in December 2015.' \
|
|
31
|
-
' LC-13 was originally used as a launch pad for early Atlas missiles ' \
|
|
32
|
-
'and rockets from Lockheed Martin. LC-1 was later expanded to ' \
|
|
33
|
-
'include Landing Zone 2 for side booster RTLS Falcon Heavy missions, ' \
|
|
34
|
-
'and it was first used in February 2018 for that purpose.'
|
|
35
|
-
)
|
|
36
|
-
end
|
|
37
|
-
end
|
|
38
|
-
|
|
39
|
-
context "#info('LZ-4')", vcr: { cassette_name: 'landing_pads/info/LZ-4' } do
|
|
40
|
-
subject do
|
|
41
|
-
SPACEX::LandingPads.info('LZ-4')
|
|
42
|
-
end
|
|
43
|
-
|
|
44
|
-
it 'returns LandingPad info for "LZ-4"' do
|
|
45
|
-
expect(subject.class).to eq SPACEX::Response
|
|
46
|
-
expect(subject.id).to eq 'LZ-4'
|
|
47
|
-
expect(subject.full_name).to eq 'Landing Zone 4'
|
|
48
|
-
expect(subject.status).to eq 'active'
|
|
49
|
-
expect(subject.location).to eq(
|
|
50
|
-
'name' => 'Vandenberg Air Force Base',
|
|
51
|
-
'region' => 'California',
|
|
52
|
-
'latitude' => 34.632989,
|
|
53
|
-
'longitude' => -120.615167
|
|
54
|
-
)
|
|
55
|
-
expect(subject.landing_type).to eq 'RTLS'
|
|
56
|
-
expect(subject.attempted_landings).to eq 2
|
|
57
|
-
expect(subject.successful_landings).to eq 2
|
|
58
|
-
expect(subject.wikipedia).to eq(
|
|
59
|
-
'https://en.wikipedia.org/wiki/' \
|
|
60
|
-
'Vandenberg_AFB_Space_Launch_Complex_4#LZ-4_landing_history'
|
|
61
|
-
)
|
|
62
|
-
expect(subject.details).to eq(
|
|
63
|
-
"SpaceX's west coast landing pad. The pad is adjacent to SLC-4E, " \
|
|
64
|
-
"SpaceX's west coast launch site. The pad was under construction for " \
|
|
65
|
-
'about a year starting in 2016. ' \
|
|
66
|
-
'After concerns with seal mating season, this pad was first used for ' \
|
|
67
|
-
'the SAOCOM 1A mission in October 2018. ' \
|
|
68
|
-
'Officially referred to as LZ-4 in FCC filings.'
|
|
69
|
-
)
|
|
70
|
-
end
|
|
71
|
-
end
|
|
72
|
-
end
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::LaunchPads do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'launch_pads/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::LaunchPads.info
|
|
7
|
-
end
|
|
8
|
-
|
|
9
|
-
it "returns all LaunchPads' info when no id is passed" do
|
|
10
|
-
first_subject = subject.first
|
|
11
|
-
|
|
12
|
-
expect(subject.class).to eq Array
|
|
13
|
-
expect(first_subject.id).to eq 5
|
|
14
|
-
expect(first_subject.name).to eq 'VAFB SLC 3W'
|
|
15
|
-
expect(first_subject.status).to eq 'retired'
|
|
16
|
-
expect(first_subject.location).to eq(
|
|
17
|
-
'name' => 'Vandenberg Air Force Base',
|
|
18
|
-
'region' => 'California',
|
|
19
|
-
'latitude' => 34.6440904,
|
|
20
|
-
'longitude' => -120.5931438
|
|
21
|
-
)
|
|
22
|
-
expect(first_subject.vehicles_launched).to eq [
|
|
23
|
-
'Falcon 1'
|
|
24
|
-
]
|
|
25
|
-
expect(first_subject.attempted_launches).to eq 0
|
|
26
|
-
expect(first_subject.successful_launches).to eq 0
|
|
27
|
-
expect(first_subject.wikipedia).to eq(
|
|
28
|
-
'https://en.wikipedia.org/wiki/Vandenberg_AFB_Space_Launch_Complex_3'
|
|
29
|
-
)
|
|
30
|
-
expect(first_subject.details).to eq 'SpaceX original ' \
|
|
31
|
-
'west coast launch pad for Falcon 1. Performed a static fire but was ' \
|
|
32
|
-
'never used for a launch and abandoned due to scheduling conflicts.'
|
|
33
|
-
expect(first_subject.site_id).to eq 'vafb_slc_3w'
|
|
34
|
-
expect(first_subject.site_name_long).to eq(
|
|
35
|
-
'Vandenberg Air Force Base Space Launch Complex 3W'
|
|
36
|
-
)
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
|
|
40
|
-
context "#info('vafb_slc_4e')", vcr: {
|
|
41
|
-
cassette_name: 'launch_pads/info/vafb_slc_4e'
|
|
42
|
-
} do
|
|
43
|
-
subject do
|
|
44
|
-
SPACEX::LaunchPads.info('vafb_slc_4e')
|
|
45
|
-
end
|
|
46
|
-
|
|
47
|
-
it 'returns LaunchPad info for "vafb_slc_4e"' do
|
|
48
|
-
expect(subject.class).to eq SPACEX::Response
|
|
49
|
-
expect(subject.id).to eq 6
|
|
50
|
-
expect(subject.name).to eq 'VAFB SLC 4E'
|
|
51
|
-
expect(subject.status).to eq 'active'
|
|
52
|
-
expect(subject.location).to eq(
|
|
53
|
-
'name' => 'Vandenberg Air Force Base',
|
|
54
|
-
'region' => 'California',
|
|
55
|
-
'latitude' => 34.632093,
|
|
56
|
-
'longitude' => -120.610829
|
|
57
|
-
)
|
|
58
|
-
expect(subject.vehicles_launched).to eq [
|
|
59
|
-
'Falcon 9'
|
|
60
|
-
]
|
|
61
|
-
expect(subject.attempted_launches).to eq 15
|
|
62
|
-
expect(subject.successful_launches).to eq 15
|
|
63
|
-
expect(subject.wikipedia).to eq(
|
|
64
|
-
'https://en.wikipedia.org/wiki/Vandenberg_AFB_Space_Launch_Complex_4'
|
|
65
|
-
)
|
|
66
|
-
|
|
67
|
-
expect(subject.details).to eq 'SpaceX primary ' \
|
|
68
|
-
'west coast launch pad for polar orbits and sun synchronous orbits, ' \
|
|
69
|
-
'primarily used for Iridium. Also intended to be capable of ' \
|
|
70
|
-
'launching Falcon Heavy.'
|
|
71
|
-
expect(subject.site_id).to eq 'vafb_slc_4e'
|
|
72
|
-
expect(subject.site_name_long).to eq(
|
|
73
|
-
'Vandenberg Air Force Base Space Launch Complex 4E'
|
|
74
|
-
)
|
|
75
|
-
end
|
|
76
|
-
end
|
|
77
|
-
end
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
describe SPACEX::Missions do
|
|
4
|
-
context '#info', vcr: { cassette_name: 'missions/info' } do
|
|
5
|
-
subject do
|
|
6
|
-
SPACEX::Missions.info
|
|
7
|
-
end
|
|
8
|
-
it 'returns missions info' do
|
|
9
|
-
expect(subject.first.mission_id).to eq 'F3364BF'
|
|
10
|
-
expect(subject.first.mission_name).to eq 'Iridium NEXT'
|
|
11
|
-
expect(subject.first.manufacturers).to eq ['Orbital ATK']
|
|
12
|
-
expect(subject.first.payload_ids).to eq ['Iridium NEXT 1', 'Iridium NEXT 2', 'Iridium NEXT 3', 'Iridium NEXT 4', 'Iridium NEXT 5', 'Iridium NEXT 6', 'Iridium NEXT 7']
|
|
13
|
-
expect(subject.first.wikipedia).to eq 'https://en.wikipedia.org/wiki/Iridium_satellite_constellation'
|
|
14
|
-
expect(subject.first.website).to eq 'https://www.iridiumnext.com/'
|
|
15
|
-
expect(subject.first.twitter).to eq 'https://twitter.com/IridiumBoss?lang=en'
|
|
16
|
-
expect(subject.first.description).to start_with 'In 2017, Iridium began launching Iridium NEXT'
|
|
17
|
-
end
|
|
18
|
-
end
|
|
19
|
-
|
|
20
|
-
context "#info('F3364BF')", vcr: { cassette_name: 'missions/F3364BF' } do
|
|
21
|
-
subject do
|
|
22
|
-
SPACEX::Missions.info('F3364BF')
|
|
23
|
-
end
|
|
24
|
-
it 'return specific mission info' do
|
|
25
|
-
expect(subject.mission_id).to eq 'F3364BF'
|
|
26
|
-
expect(subject.mission_name).to eq 'Iridium NEXT'
|
|
27
|
-
expect(subject.manufacturers).to eq ['Orbital ATK']
|
|
28
|
-
expect(subject.payload_ids).to eq ['Iridium NEXT 1', 'Iridium NEXT 2', 'Iridium NEXT 3', 'Iridium NEXT 4', 'Iridium NEXT 5', 'Iridium NEXT 6', 'Iridium NEXT 7']
|
|
29
|
-
expect(subject.wikipedia).to eq 'https://en.wikipedia.org/wiki/Iridium_satellite_constellation'
|
|
30
|
-
expect(subject.website).to eq 'https://www.iridiumnext.com/'
|
|
31
|
-
expect(subject.twitter).to eq 'https://twitter.com/IridiumBoss?lang=en'
|
|
32
|
-
expect(subject.description).to start_with 'In 2017, Iridium began launching Iridium NEXT, a second-generation worldwide network of telecommunications satellites, consisting of 66 active satellites, with another nine in-orbit spares and six on-ground spares.'
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
end
|