Closed griffobeid closed 6 years ago
@griffobeid
How would these tests be helpful in verifying the project. It will require hardcoding of every single state, and every single property in the state in the test, basically just replicating what is already in missionProgress.js
... in fact, I would go as far as to say it reduces the reliability of the code because you now have to keep everything up to date in two places.
However, there are many other opportunities for other tests in this file (which is where I am guessing you were going with this next)... specifically testing the conditionForNextUpdate()
of the various states. We can definitely call those with different mission parameters and see when it says the state needs to update, and when it shouldn't.
@TalAter Gotcha. I'll look into a more useful test for this file.
Thank you for your help ❤️
What is this project?
DAV (Decentralized Autonomous Vehicles) is a new non-profit foundation working to build an open-source infrastructure for autonomous vehicles (cars, drones, trucks, robots, and all the service providers around them) to communicate and transact with each other over blockchain.
As an organization that believes in building a large community of open-source contributors, we often create issues like this one to help people take their first few steps into the world of open source.
Mission Control
The specific project you are looking at is Mission Control. It is the brain in charge of orchestrating missions between DAV users and autonomous vehicles.
How you can help
The Issue
Mission Control comes with a built in simulation environment which generates and controls simulated vehicles, allowing developers to start developing without investing in costly hardware first.
One part of the simulation environment is the
missionProgress
script. This script assists the vehicle to know its current status and what it should do next. We need to make sure with a test that thetravelling_pickup
status contains what it is supposed to.What you can do
Write a test in a new file called
simulation.missionProgress.spec.js
that tests the output of thetravelling_pickup
status in themissionProgress
script. The test should make suremissionProgress['travelling_pickup']
contains astatus
,nextVehicleStatus
,nextMissionUpdate
, andconditionForNextUpdate
.Contributing to Mission Control
Asking for help
We appreciate your effort in taking the time to work on this issue and help out the open source community and the foundation. If you need any help, feel free to ask below or in our gitter channel. We are always happy to help 😄