Run tests for gems in different steps

This commit is contained in:
Eloy Pérez 2022-02-05 12:30:48 +01:00
parent c7e851f7d7
commit 2c9be5df00
2 changed files with 12 additions and 21 deletions

View File

@ -1,19 +0,0 @@
#!/bin/bash
set -ev
echo "Running sinatra tests..."
bundle exec rake
echo "Running sinatra-contrib tests..."
export BUILDIR=$GITHUB_WORKSPACE/sinatra-contrib
export BUNDLE_GEMFILE=$BUILDIR/Gemfile
cd $BUILDIR
bundle install --jobs=3 --retry=3
bundle exec rake
echo "Running rack-protection tests..."
export BUILDIR=$GITHUB_WORKSPACE/rack-protection
export BUNDLE_GEMFILE=$BUILDIR/Gemfile
cd $BUILDIR
bundle install --jobs=3 --retry=3
bundle exec rake

View File

@ -24,8 +24,18 @@ jobs:
bundler-cache: true
- name: Install dependencies
run: sudo apt-get install -y pandoc nodejs pkg-config libxml2-dev libxslt-dev
- name: Run tests
run: ./.actions.sh
- name: Run sinatra tests
run: bundle exec rake
- name: Run sinatra-contrib tests
run: |
cd $GITHUB_WORKSPACE/sinatra-contrib
bundle install --jobs=3 --retry=3
bundle exec rake
- name: Run rack-protection tests
run: |
cd $GITHUB_WORKSPACE/rack-protection
bundle install --jobs=3 --retry=3
bundle exec rake
- uses: 8398a7/action-slack@v3
with:
status: ${{ job.status }}