Skip to content

Intake for application process for Connected Communities BC funding program

License

Notifications You must be signed in to change notification settings

button-inc/CONN-CCBC-portal

 
 

Repository files navigation

Lifecycle:Experimental

CONN-CCBC-portal

Database Setup

Have a local instance of postges running, then do the following:

$ cd db
$ createdb ccbc
$ sqitch deploy

Environment Variables

This project uses node-convict to declare environment variables. Variables for each environment are declared in development.json, test.json or production.json.

The defaults can be overridden directly or in an .env file.

Running the Application

Run the following commands:

$ cd app
$ yarn
$ yarn dev

Running PGTap database tests locally

Install pg_prove:

sudo cpan TAP::Parser::SourceHandler::pgTAP

Install PGTap:

$ git clone https://github.com/theory/pgtap.git
$ cd pgtap
$ git checkout v1.2.0
$ git branch
$ make
$ sudo make install
$ psql -c 'CREATE EXTENSION pgtap;'

Run tests:

In the project root run:

pg_prove --username postgres --dbname ccbc db/test/*/*_test.sql

Running Jest and end to end tests locally

Jest

In /app directory run yarn test

End to end tests:

Cypress and Happo is used for end to end testing. A Happo account and API secret + key is required for Happo testing though it is automatically disabled if no keys exist. Happo is free for open source projects.

To run the end to end tests we need to run our development server in one terminal with the command:

yarn dev

Once that is running in a second terminal run:

yarn test:e2e

About

Intake for application process for Connected Communities BC funding program

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 61.8%
  • PLpgSQL 28.8%
  • Makefile 3.9%
  • JavaScript 3.6%
  • Dockerfile 1.3%
  • Smarty 0.3%
  • Other 0.3%