Skip to content

A Boilerplate for NodeJs and Postgres Applications - Built for hackathons (authentication and email verification included)

License

Notifications You must be signed in to change notification settings

ogwurujohnson/nodepost

Repository files navigation

nodePOST--Hack

A Boilerplate for NodeJs and Postgres Applications

Implemented Features

  • Users can create an account and login.
  • Users can verify their account via their email.

Technologies Used

Testing tools

  • Mocha - A Javascript test framework.
  • Chai - Assertion library.
  • Istanbul - Javascript code instrumenter.
  • nyc - Istanbul's command line interface.
  • coveralls - lcov posting to coveralls.io

Getting Started

Installation

  • Install NodeJs and PostgreSQL on your computer.
  • Clone this repository using git clone https://github.com/ogwurujohnson/nodepost--Hack.git.
  • Set up your environment variables in a .env file.
  • Create production, development and test db's. specify their names in your env file
  • Run npm install to install all dependencies.
  • Run npm run migration to run DB migrations.
  • Run npm run dev to start the server.
  • Navigate to localhost:3000/api/v1 in your browser to access the application.

Testing the application

Requirements

  • Postman - API development and testing environment.

Testing with Postman

  • Install Postman by following the link above.
  • Navigate to localhost:3000 in Postman to access the application.
  • Use the API Documentation to access the endpoints available (link will be available soon).

Running unit tests.

  • In an open terminal, navigate to the cloned project file.
  • Before running test, please change NODE_ENV='test' , still looking for a fix for this
  • Then on your console run npm run migration
  • Run npm run test-travis. This runs tests and displays coverage data generated by Istanbul's nyc.

Author

Ogwuru Johnson

About

A Boilerplate for NodeJs and Postgres Applications - Built for hackathons (authentication and email verification included)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published