mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 01:17:18 +02:00
Merge branch 'use-new-codeclimate-test-reporter' into registry-660
This commit is contained in:
commit
a39dd9cc0c
5 changed files with 23 additions and 18 deletions
12
.travis.yml
12
.travis.yml
|
@ -9,14 +9,16 @@ before_script:
|
||||||
- "psql -c 'create database registry_api_log_test;' -U postgres"
|
- "psql -c 'create database registry_api_log_test;' -U postgres"
|
||||||
- "cp config/application-example.yml config/application.yml"
|
- "cp config/application-example.yml config/application.yml"
|
||||||
- "cp config/database-travis.yml config/database.yml"
|
- "cp config/database-travis.yml config/database.yml"
|
||||||
- "RAILS_ENV=test bundle exec rake db:setup:all"
|
- "bundle exec rake db:setup:all"
|
||||||
|
- "curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter"
|
||||||
|
- "chmod +x ./cc-test-reporter"
|
||||||
|
- "./cc-test-reporter before-build"
|
||||||
script:
|
script:
|
||||||
- "RAILS_ENV=test bundle exec rspec"
|
- "bundle exec rspec"
|
||||||
- "bundle exec rake test"
|
- "bundle exec rake test"
|
||||||
after_success:
|
after_script:
|
||||||
- "bundle exec codeclimate-test-reporter"
|
- "./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT"
|
||||||
services:
|
services:
|
||||||
- postgresql
|
- postgresql
|
||||||
addons:
|
addons:
|
||||||
postgresql: "9.4"
|
postgresql: "9.4"
|
||||||
code_climate:
|
|
||||||
|
|
3
Gemfile
3
Gemfile
|
@ -137,7 +137,6 @@ end
|
||||||
|
|
||||||
group :test do
|
group :test do
|
||||||
gem 'database_cleaner'
|
gem 'database_cleaner'
|
||||||
gem 'codeclimate-test-reporter', "~> 1.0.0"
|
gem 'simplecov', require: false
|
||||||
gem 'simplecov'
|
|
||||||
gem 'webmock'
|
gem 'webmock'
|
||||||
end
|
end
|
||||||
|
|
|
@ -142,8 +142,6 @@ GEM
|
||||||
xpath (~> 2.0)
|
xpath (~> 2.0)
|
||||||
chronic (0.10.2)
|
chronic (0.10.2)
|
||||||
cliver (0.3.2)
|
cliver (0.3.2)
|
||||||
codeclimate-test-reporter (1.0.8)
|
|
||||||
simplecov (<= 0.13)
|
|
||||||
coderay (1.1.0)
|
coderay (1.1.0)
|
||||||
coercible (1.0.0)
|
coercible (1.0.0)
|
||||||
descendants_tracker (~> 0.0.1)
|
descendants_tracker (~> 0.0.1)
|
||||||
|
@ -413,11 +411,11 @@ GEM
|
||||||
thor (~> 0.14)
|
thor (~> 0.14)
|
||||||
selectize-rails (0.12.1)
|
selectize-rails (0.12.1)
|
||||||
sexp_processor (4.8.0)
|
sexp_processor (4.8.0)
|
||||||
simplecov (0.10.0)
|
simplecov (0.15.1)
|
||||||
docile (~> 1.1.0)
|
docile (~> 1.1.0)
|
||||||
json (~> 1.8)
|
json (>= 1.8, < 3)
|
||||||
simplecov-html (~> 0.10.0)
|
simplecov-html (~> 0.10.0)
|
||||||
simplecov-html (0.10.0)
|
simplecov-html (0.10.2)
|
||||||
simpleidn (0.0.7)
|
simpleidn (0.0.7)
|
||||||
sinatra (1.4.8)
|
sinatra (1.4.8)
|
||||||
rack (~> 1.5)
|
rack (~> 1.5)
|
||||||
|
@ -488,7 +486,6 @@ DEPENDENCIES
|
||||||
bundler-audit
|
bundler-audit
|
||||||
cancancan (= 1.11.0)
|
cancancan (= 1.11.0)
|
||||||
capybara
|
capybara
|
||||||
codeclimate-test-reporter (~> 1.0.0)
|
|
||||||
coderay (= 1.1.0)
|
coderay (= 1.1.0)
|
||||||
coffee-rails (= 4.1.0)
|
coffee-rails (= 4.1.0)
|
||||||
countries
|
countries
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
|
if ENV['COVERAGE']
|
||||||
|
require 'simplecov'
|
||||||
|
SimpleCov.command_name 'spec'
|
||||||
|
SimpleCov.start 'rails'
|
||||||
|
end
|
||||||
|
|
||||||
require 'webmock/rspec'
|
require 'webmock/rspec'
|
||||||
WebMock.disable_net_connect!(allow_localhost: true)
|
WebMock.disable_net_connect!(allow_localhost: true)
|
||||||
|
|
||||||
if ENV['TRAVIS']
|
|
||||||
require 'simplecov'
|
|
||||||
SimpleCov.start
|
|
||||||
end
|
|
||||||
|
|
||||||
RSpec.configure do |config|
|
RSpec.configure do |config|
|
||||||
# rspec-expectations config goes here. You can use an alternate
|
# rspec-expectations config goes here. You can use an alternate
|
||||||
# assertion/expectation library such as wrong or the stdlib/minitest
|
# assertion/expectation library such as wrong or the stdlib/minitest
|
||||||
|
|
|
@ -1,3 +1,9 @@
|
||||||
|
if ENV['COVERAGE']
|
||||||
|
require 'simplecov'
|
||||||
|
SimpleCov.command_name 'test'
|
||||||
|
SimpleCov.start 'rails'
|
||||||
|
end
|
||||||
|
|
||||||
ENV['RAILS_ENV'] ||= 'test'
|
ENV['RAILS_ENV'] ||= 'test'
|
||||||
require File.expand_path('../../config/environment', __FILE__)
|
require File.expand_path('../../config/environment', __FILE__)
|
||||||
require 'rails/test_help'
|
require 'rails/test_help'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue