mirror of
https://github.com/internetee/registry.git
synced 2025-05-18 02:09:39 +02:00
28 lines
650 B
Bash
Executable file
28 lines
650 B
Bash
Executable file
#!/bin/bash -e
|
|
|
|
#
|
|
# Build and run everything for automatic tests
|
|
#
|
|
git pull origin master
|
|
bundle install --deployment
|
|
|
|
# cp config/secrets-example.yml config/secrets.yml
|
|
# create manually config/database.yml
|
|
|
|
RAILS_ENV=test bundle exec rake db:reset
|
|
RAILS_ENV=test bundle exec rake assets:precompile
|
|
|
|
echo "GIT_LAST_COMMITS"
|
|
git log origin/master -n 15 --pretty=oneline | sed -r '/^.{40} Merge branch/d' | sed -r 's/^.{40}/Latests: /'
|
|
echo "END_OF_GIT_LAST_COMMITS"
|
|
|
|
# run rubocop
|
|
echo "RUBOCOP_RESULTS"
|
|
rubocop
|
|
echo "END_OF_RUBOCOP_RESULTS"
|
|
|
|
# run tests
|
|
echo "TEST_RESULTS"
|
|
RAILS_ENV=test bundle exec rake test:other
|
|
echo "END_OF_TEST_RESULTS"
|
|
|