A simple Rails 6 app designed to provide a basic API for our code test.
- Ruby (2.5+) or an environment like Docker (see below)
-
Run
bundle installto install gems -
Run
bin/rails db:setupto migrate and seed your development database -
Run
bin/rails serverto start up the local development server
You should get JSON output from http://localhost:3000/members
Run bin/rspec to run the test suite.
As an alternative to installing Ruby directly, you can use the provided Docker files to run the app and test suite.
- Run
docker-compose up -dto start the Docker container (gems are installed and the server is booted automatically) - Run
docker-compose exec web bin/rails db:setupto set up the database - Run
docker-compose exec web bin/rspecto test
If necessary, you can restart the Rails server with docker-compose restart