Description: Home task for Automate FE
Owner: Automate Frontend
Contacts: [email protected], [email protected]
Welcome to our little coding exercise. During this test you will be given the opportunity to play with Javascript and rockets in the same project. Some people might be horrified at the thought of this even being a possibility, but Javascript is what we do isn't it?
Before you begin please make sure you read this readme file entirely and that you understand everything. If there's anything that you don't understand, please don't hesitate to reach out and ask.
We'd like to give all candidates taking this test the same opportunity to solve the exercise in their own way, because of this we kindly ask you not to fork or share this repo (or your solution) with anybody
- Clone this repo to a location of your choosing.
- Read all of the 'Exercise' part before you start.
- Write your solution to the exercise making sure the provided tests are green.
- Push your solution to a private repo in your personal Github account.
- When you are ready for us to take a look add users
paul-pro
,AragonCodes
,Sc4ramouche
andkotik-adjust
as collaborators to your repo.
Using the past launches endpoint from the SpaceX API consolidate a list of all the missions that were launched in 2018 that carried a payload belonging to NASA. Missions should appear in inverse chronological order, with the exception of those that carried more payloads should appear first.
Display the outcome of your solution by rendering the list to the screen as JSON while keeping an indentation of 2 spaces. To make the evaluation process simpler we only care to see the flight number, the mission name, and the amount of payloads carried by each mission.
Your solution is expected to render the following:
[
{
"flight_number": 62,
"mission_name": "Iridium NEXT Mission 6",
"payloads_count": 2
},
{
"flight_number": 72,
"mission_name": "CRS-16",
"payloads_count": 1
},
{
"flight_number": 64,
"mission_name": "CRS-15",
"payloads_count": 1
},
{
"flight_number": 60,
"mission_name": "TESS",
"payloads_count": 1
},
{
"flight_number": 59,
"mission_name": "CRS-14",
"payloads_count": 1
}
]
- We expect that your solution would be parameterizable, it has already been reflected in tests, just make sure that your code passes them
- Make sure the specs are green
- You can use any utility library you see fit (please don't use React, Angular or Vue).
- You can request the data from
https://api.spacexdata.com/v3/launches/past
, but you are not allowed to use any of the filter parameters provided by the SpaceX API. - It doesn't matter to which NASA program each payload belongs to as long as NASA is the customer.
- Payloads are carried in the second stage of a rocket and they can belong to multiple customers.
- Please use UTC dates for anything time related.