ziishaned / sabbar-challenge-test

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

sabbar-challenge-test

Demo

Listing

Listing

Update

Update

Delete

Delete

Create

Create

Getting started

  1. Clone the repository

    git clone git@github.com:ziishaned/sabbar-challenge-test.git
    
  2. Install dependencies for backend:

    cd backend
    yarn install
  3. Install dependencies for frontend:

    cd frontend
    yarn install
  4. Start the application by running below command in the root of the project:

    yarn dev
  5. Seed the database with below command:

    cd backend
    yarn seed
  6. Application URLs:

    frontend: http://localhost:3000/
    backend: http://localhost:3001/

Available CLI commands

Usage: sabbar [options] [command]

Options:
  -V, --version       output the version number
  -h, --help          display help for command

Commands:
  customer [options]  Show existing list of customers
  cruiser [options]   Show existing list of cruisers
  manual              Show this help
  exit                Kill the CLI (and the rest of the application)
  help [command]      display help for command

Usage

To run any command use below pattern:

yarn cli [command-name]

customer

This command will display the list of customers. It also accepts some options which can help you to navigate through pages or limit the number of results to display in terminal.

customer

cruiser

This command acts just like customer. The only difference is that this will display only cruiser (Drivers) in terminal.

cruiser

manual

You can view the help screen using this command.

manual

exit

This command will kill the CLI.

exit

Importing Postman Collection

Copy below link and import in postman:

https://www.getpostman.com/collections/4a3e055c9d0bb6ee6517

Postman

Tests

I was not able to add tests due to lack of time, but the test should have been there.

About


Languages

Language:TypeScript 95.6%Language:JavaScript 4.4%