Skip to content

vinodnextcoder/ride-sharing-geektrust

Repository files navigation

geektrust ride sharing

  • Your task is to build a solution that will help to match riders with drivers based on their location and generate a bill for the ride.

Pre-requisites

  • NodeJS 12.6.0/14.15.4/16.10.0
  • npm

How to run the code

We have provided scripts to execute the code.

Use run.sh if you are Linux/Unix/macOS Operating systems and run.bat if you are on Windows. Both the files run the commands silently and prints only output from the input file sample_input/input1.txt. You are supposed to add the input commands in the file from the appropriate problem statement.

Internally both the scripts run the following commands

  • npm ci --silent - This will build the solution downloading the necessary dependencies.
  • Once the npm install from the previous build process is complete, we will execute the program using the command

npm start --silent sample_input/input1.txt

How to execute the unit tests

Mocha based test cases are executed with the following command from the root folder mocha test