Skip to content

Instantly share code, notes, and snippets.

@hadrienblanc
Created April 29, 2019 09:20
Show Gist options
  • Save hadrienblanc/4537e11ce1cb7e70256f5ea40ffd372e to your computer and use it in GitHub Desktop.
Save hadrienblanc/4537e11ce1cb7e70256f5ea40ffd372e to your computer and use it in GitHub Desktop.
classique circle_ci rails test config file
# classique circle_ci rails test config file
version: 2
jobs:
build:
environment:
working_directory: ~/circleci-myapp
docker:
- image: circleci/ruby:2.5.5-node-browsers
steps:
- checkout
# Install gem dependencies
- run: |
gem update --system
gem install bundler
- run: bundle install #--path vendor/bundle
# Database setup
- run: bin/rails RAILS_ENV=test db:create
- run: bin/rails RAILS_ENV=test db:migrate
- run: bin/rails RAILS_ENV=test db:seed
# Run Ruby unit tests and app integration tests in parallel
- type: shell
command: |
bundle exec bin/rails test $(circleci tests glob "test/**/*_test.rb")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment