W01fw00d / escaping_boredom

Prototype of a Reviews App (Escape Rooms)

Home Page:https://escaping-boredom.herokuapp.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Escaping Boredom Logo

Node.js CI

How to use

  1. Install dependencies
npm install
  1. Deploy Front App
npm run dev-front
  1. Deploy Back App

Launch a mongoDB and then:

npm run dev-back

If you need to restart the server:

rs
  • chemistry-ui as local dependency (for development and testing)

"npm link" is useful, but there're some issues regarding having different "react" and "react-router-dom" instances.

To solve this, you can execute this bash script that will perform the correct linking:

(Note: You can use Git Bash to be able to execute that in Windows)

sh link.sh
  • Launch Jasmine (Unit Tests)
npm run utest
  • Launch Cypress (Functional Tests)
npm run dev-front

Launch without ui

npm run ftest

Launch only a spec

npm run ftest-spec cypress/integration/[spec-file-name].spec.js

Launch with ui

npm run ftest-ui
  • Build
npm run build

Functional description

  • When the App is launched, real data como from node.js server.

  • When Cypress Tests are launched, fake data is used from randomized JSONs.

Technical Stack



  • React

  • Node

  • MongoDB

  • Babel (compilation)

  • Webpack (bundling)

  • Jasmine: Unit Testing Tool

  • Cypress: Integration Testing Tool

  • Chemistry-UI: my own Components Library, based on Material-UI.

  • Prettier, ESLint (code style tools, based on airbnb conventions), Husky (pre-commit automated formatting tool)

  • Heroku: deploying free site for this App Demo

Technical discusion

  • A pre-commit has been added to this repository to help maintain a coherent code style, even if new developers were added to this project in the future.

  • Literals are not hardcoded but instead passed down to components by props in order to implement a multilanguage support system in the future.

  • A random number and string generator has been added to Cypress Tests in order to garantee that different data will fit correctly on the UI (for example, this simulates the effect of having different languages).

  • Build and unit tests are executed on the CI in GitHub with every push to master and pull request.

Atribution

About

Prototype of a Reviews App (Escape Rooms)

https://escaping-boredom.herokuapp.com/


Languages

Language:JavaScript 94.3%Language:HTML 3.8%Language:Shell 1.9%