Skip to content

Commit 48db05b

Browse files
committed
move v2 capsules to unique file
1 parent f7138af commit 48db05b

File tree

1 file changed

+0
-56
lines changed

1 file changed

+0
-56
lines changed

test/v2-routes.test.js renamed to test/v2-capsules.test.js

Lines changed: 0 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -9,62 +9,6 @@ beforeAll((done) => {
99
});
1010
});
1111

12-
//------------------------------------------------------------
13-
// Capsule V2
14-
//------------------------------------------------------------
15-
16-
test('It should return all v2 capsules', () => {
17-
return request(app).get('/v2/parts/caps').then((response) => {
18-
expect(response.statusCode).toBe(200);
19-
response.body.forEach((item) => {
20-
expect(item).toHaveProperty('capsule_serial');
21-
expect(item).toHaveProperty('capsule_id');
22-
expect(item).toHaveProperty('status');
23-
expect(item).toHaveProperty('original_launch');
24-
expect(item.missions.length).toBeGreaterThan(0);
25-
expect(item).toHaveProperty('landings');
26-
expect(item).toHaveProperty('type');
27-
expect(item).toHaveProperty('details');
28-
});
29-
});
30-
});
31-
32-
test('It should return capsule C101', () => {
33-
return request(app).get('/v2/parts/caps/C101').then((response) => {
34-
expect(response.statusCode).toBe(200);
35-
expect(response.body).toHaveProperty('capsule_serial', 'C101');
36-
});
37-
});
38-
39-
//------------------------------------------------------------
40-
// Core V2
41-
//------------------------------------------------------------
42-
43-
test('It should return all v2 cores', () => {
44-
return request(app).get('/v2/parts/cores').then((response) => {
45-
expect(response.statusCode).toBe(200);
46-
response.body.forEach((item) => {
47-
expect(item).toHaveProperty('core_serial');
48-
expect(item).toHaveProperty('status');
49-
expect(item).toHaveProperty('original_launch');
50-
expect(item.missions.length).toBeGreaterThan(0);
51-
expect(item).toHaveProperty('rtls_attempt');
52-
expect(item).toHaveProperty('rtls_landings');
53-
expect(item).toHaveProperty('asds_attempt');
54-
expect(item).toHaveProperty('asds_landings');
55-
expect(item).toHaveProperty('water_landing');
56-
expect(item).toHaveProperty('details');
57-
});
58-
});
59-
});
60-
61-
test('It should return core B0007', () => {
62-
return request(app).get('/v2/parts/cores/B0007').then((response) => {
63-
expect(response.statusCode).toBe(200);
64-
expect(response.body).toHaveProperty('core_serial', 'B0007');
65-
});
66-
});
67-
6812
//------------------------------------------------------------
6913
// Dragon V2
7014
//------------------------------------------------------------

0 commit comments

Comments
 (0)