Skip to content

Commit

Permalink
Create the test-integration docker-compose.yml file
Browse files Browse the repository at this point in the history
The followihng test-integration and init.sh file will start up the
container using the docker-composer file. afterwards it will do some
installation and then run the tests.
Also fixed typo in file name of docker-compose
  • Loading branch information
VadimSchmitz committed Mar 2, 2022
1 parent afb107b commit e6466e0
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 23 deletions.
53 changes: 30 additions & 23 deletions .github/workflows/test-integration.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,32 @@
name: test-integration
on:
pull_request:
push:
branches: [master, develop, feature/gha-testintegration]
env:
APP_ENV: test
pull_request:
push:
branches: [master, develop]
jobs:
run_test:
##should be changed to the correct docker image
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1

## installing composer should be obselete due to running on a provisioned docker container soon.
# - name: install composer and update to latest version
# - composer self-update --1
# - composer install --prefer-dist

## looking into how to change ant to composer scripts in the future.
- name: install packages
#install ant
- name: run scripts
## ant should be changed to a composer script somehow
- ant
- composer test
build:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
- uses: actions/cache@v1
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Init environment
run: |
cd ci/docker
docker-compose up -d
docker-compose exec -t ra-test bash
- name: Composer install
run: composer install
- name: Run test scripts
run: composer test
- name: Output log files on failure
if: failure()
run: cd ci/docker && docker-compose exec -T ra-test cat var/log/error.log
File renamed without changes.

0 comments on commit e6466e0

Please sign in to comment.