Fix circle

This commit is contained in:
Ari Timonen 2020-03-25 00:46:05 +02:00
parent ff62add19f
commit 6d142ea799
4 changed files with 12 additions and 9 deletions

View file

@ -53,11 +53,11 @@ jobs:
# sudo composer self-update # sudo composer self-update
# composer install -n --prefer-dist # composer install -n --prefer-dist
# download test reporter as a static binary # download test reporter as a static binary
- run: # - run:
name: Setup Code Climate test-reporter # name: Setup Code Climate test-reporter
command: | # command: |
curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter # curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
chmod +x ./cc-test-reporter # chmod +x ./cc-test-reporter
# Only necessary if app uses webpacker or yarn in some other way # Only necessary if app uses webpacker or yarn in some other way
#- restore_cache: #- restore_cache:
# keys: # keys:
@ -105,10 +105,10 @@ jobs:
- run: - run:
command: | command: |
mkdir /tmp/test-results mkdir /tmp/test-results
./cc-test-reporter before-build # ./cc-test-reporter before-build
TESTFILES=$(circleci tests glob "spec/**/*_spec.rb" | circleci tests split --split-by=timings) TESTFILES=$(circleci tests glob "spec/**/*_spec.rb" | circleci tests split --split-by=timings)
bundle exec rspec $TESTFILES --profile 10 -r rspec_junit_formatter --format RspecJunitFormatter --out /tmp/test-results/rspec.xml --format progress bundle exec rspec $TESTFILES --profile 10 -r rspec_junit_formatter --format RspecJunitFormatter --out /tmp/test-results/rspec.xml --format progress
./cc-test-reporter after-build --coverage-input-type clover --exit-code $? # ./cc-test-reporter after-build --coverage-input-type clover --exit-code $?
- store_test_results: - store_test_results:
path: /tmp/test-results path: /tmp/test-results
- store_artifacts: - store_artifacts:

View file

@ -90,7 +90,7 @@ end
group :test do group :test do
# gem 'spring' # gem 'spring'
gem 'capybara' gem 'capybara'
# gem 'codeclimate-test-reporter', require: nil gem 'codeclimate-test-reporter', require: nil
# FIXME: Downgraded b/c of deprecations, fix static attributes # FIXME: Downgraded b/c of deprecations, fix static attributes
gem 'factory_bot_rails', '4.10.0' gem 'factory_bot_rails', '4.10.0'
gem 'phantomjs', require: 'phantomjs/poltergeist' gem 'phantomjs', require: 'phantomjs/poltergeist'

View file

@ -150,6 +150,8 @@ GEM
mini_mime (>= 0.1.3) mini_mime (>= 0.1.3)
childprocess (3.0.0) childprocess (3.0.0)
cliver (0.3.2) cliver (0.3.2)
codeclimate-test-reporter (1.0.7)
simplecov
coderay (1.1.2) coderay (1.1.2)
coffee-rails (5.0.0) coffee-rails (5.0.0)
coffee-script (>= 2.2.0) coffee-script (>= 2.2.0)
@ -454,6 +456,7 @@ DEPENDENCIES
bourbon (~> 3.1.8) bourbon (~> 3.1.8)
capybara capybara
carrierwave carrierwave
codeclimate-test-reporter
coffee-rails coffee-rails
country_select country_select
dalli (~> 2.7.0) dalli (~> 2.7.0)

View file

@ -3,7 +3,7 @@ ENV["RAILS_ENV"] ||= "test"
require 'dotenv' require 'dotenv'
Dotenv.load() Dotenv.load()
# require "codeclimate-test-reporter" require "codeclimate-test-reporter"
require "simplecov" require "simplecov"
# CodeClimate::TestReporter.start # CodeClimate::TestReporter.start