Sha256: 94bdb03ce96047fbb8657ae60c83faf4a70f9a6305c09fefb44e4993b7998e86

Contents?: true

Size: 1.9 KB

Versions: 2

Compression:

Stored size: 1.9 KB

Contents

#!/usr/bin/env bash

set -eo pipefail

echo ""
echo "== Yamllint: =="
yamllint --config-file lib/install/.yamllint.yml --strict .*/*.yml
yamllint --config-file lib/install/.yamllint.yml --strict *.yml
yamllint --config-file lib/install/.yamllint.yml --strict lib/**/.*.yml
yamllint --config-file lib/install/.yamllint.yml --strict **/.*/*.yml

mkdir -p tmp/

cd tmp
rm -rf test_tmpl

# Test installation of missed gems on applying template
gem uninstall oj || true

if [[ "$TEST_APP_TEMPLATE" == "true" ]]
then
  rails new test_tmpl --quiet --database postgresql --skip-webpack-install
  cd test_tmpl
  bin/setup
  bin/rails app:template LOCATION="../../template.rb"
else
  rails new test_tmpl --template ../template.rb --quiet --database postgresql --skip-webpack-install
  cd test_tmpl
  bin/setup
fi

echo ""
echo "== Verify CircleCI config =="
circleci config validate

echo ""
echo "== Verify installation scripts =="
bin/tools-setup
bin/tools-upgrade

echo ""
echo "== Verify linters setup =="

git add .
git commit -m 'Initial Commit'
git checkout -b origin/master

git checkout -b test_pr

echo " => class SampleForLinters;end" > sample_for_linters.rb

git add .
git commit -m 'Adds sample_for_linters'

bin/rubocop --fail-level F sample_for_linters.rb
bin/pronto run -c HEAD~1 --no-exit-code
BUNDLE_GEMFILE=Gemfile.tools bin/bundle exec rails_best_practices --without-color --silent --test .
# FIXME: https://github.com/Shopify/erb-lint/issues/162
# BUNDLE_GEMFILE=Gemfile.tools bin/bundle exec erblint --config ../../lib/install/.erb-lint.yml --autocorrect .

CIRCLECI=false bin/lint-pr -f text

echo ""
echo "== Run git hooks verifications =="
bin/git-hooks/post-merge
CIRCLECI=false bin/git-hooks/pre-push

bin/rubocop --config ../../lib/install/.rubocop.yml --debug --extra-details --display-style-guide --parallel ../../lib
node_modules/.bin/eslint --config ../../lib/install/.eslintrc.js --quiet --no-color ../../lib/**/.*.js

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
jt_tools-0.0.14 bin/test
jt_tools-0.0.13 bin/test