2016-09-15 21:33:05 +05:30
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
if [ -z "$ADTTMP" ]; then
|
|
|
|
ADTTMP=$(mktemp -d)
|
|
|
|
cleanup() {
|
|
|
|
rm -rf "$ADTTMP"
|
|
|
|
}
|
|
|
|
trap cleanup INT TERM EXIT
|
|
|
|
fi
|
|
|
|
|
|
|
|
cd $ADTTMP
|
|
|
|
|
|
|
|
exec 2>&1
|
|
|
|
set -ex
|
|
|
|
|
|
|
|
cd /usr/share/gitlab
|
|
|
|
sudo truncate -s 0 Gemfile.lock
|
|
|
|
if ! grep factory_girl_rails Gemfile >/dev/null; then
|
|
|
|
cp Gemfile ${ADTTMP}
|
|
|
|
cat <<EOF >> ${ADTTMP}/Gemfile
|
|
|
|
gem 'factory_girl_rails', '~> 4.6'
|
|
|
|
gem 'rspec-rails', '~> 3.4'
|
|
|
|
gem 'rspec-retry', '~> 0.4.3'
|
|
|
|
gem 'capybara', '~> 2.5'
|
|
|
|
gem 'poltergeist', '~> 1.9'
|
|
|
|
gem 'capybara-screenshot', '~> 1.0'
|
|
|
|
gem 'database_cleaner', '~> 1.5'
|
|
|
|
gem 'email_spec', '~> 1.6'
|
|
|
|
gem 'ffaker', '~> 2.0'
|
2016-09-16 00:02:48 +05:30
|
|
|
gem 'json-schema', '~> 2.6', '>= 2.6.2'
|
2016-09-15 21:33:05 +05:30
|
|
|
EOF
|
|
|
|
sudo cp ${ADTTMP}/Gemfile .
|
|
|
|
fi
|
|
|
|
|
|
|
|
export $(cat /etc/gitlab/gitlab-debian.conf)
|
2016-09-16 13:40:08 +05:30
|
|
|
sudo -u gitlab -E -H bundle install --local
|
|
|
|
sudo -u gitlab -E -H bundle exec rspec spec/uploaders spec/routing spec/views \
|
2016-09-16 13:46:07 +05:30
|
|
|
spec/factories_spec.rb spec/finders
|
2016-09-16 00:02:48 +05:30
|
|
|
|
|
|
|
#config 2/2 failed, controllers many failed
|