-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SC-9416: Migrate from Travis to Github Actions (#324)
* SC-9416: added boot-syntax-check-tests.yml + deploy-file-builder-tests.yml * SC-9416: added b2b+b2c support * SC-9416: added all images with php 7.4 * SC-9416: added all images with php 7.4 * SC-9416: optimized image matrix
- Loading branch information
Showing
4 changed files
with
189 additions
and
161 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
name: B2B + B2C Demoshop tests | ||
on: | ||
- push | ||
|
||
env: | ||
SPRYKER_TESTING_ENABLED: 1 | ||
PROJECT: suite | ||
|
||
jobs: | ||
functional_test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform-image: [ | ||
'spryker/php:7.4-alpine3.14', | ||
'spryker/php:7.4-debian' | ||
] | ||
application-store: [ 'DE' ] | ||
env: [ | ||
'ci.mysql', | ||
'ci.pgsql' | ||
] | ||
repo: [ | ||
'https://github.com/spryker-shop/b2b-demo-shop.git', | ||
'https://github.com/spryker-shop/b2c-demo-shop.git' | ||
] | ||
name: "Function Tests(Image: ${{ matrix.platform-image }}, Environment: ${{ matrix.env }}, Repo: ${{ matrix.repo }})" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Clone demo shop | ||
run: cd ../ && git clone --depth=3 --branch=master ${{ matrix.repo }} demo-shop && cp -R docker-sdk demo-shop | ||
|
||
- name: Provide env variables | ||
run: | | ||
export SPRYKER_PLATFORM_IMAGE=${{ matrix.platform-image}} | ||
export APPLICATION_ENV=${{ matrix.env }} | ||
export APPLICATION_STORE=${{ matrix.application-store }} | ||
- name: Run script | ||
run: | | ||
cd ../demo-shop | ||
docker-sdk/sdk boot deploy.ci.functional.mariadb.yml -v | ||
docker-sdk/sdk up -t -v | ||
docker-sdk/sdk testing codecept run -c codeception.ci.functional.yml | ||
glue_test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform-image: [ | ||
'spryker/php:7.4-alpine3.15', | ||
'spryker/php:7.4-debian-buster' | ||
] | ||
application-store: [ 'DE' ] | ||
env: [ | ||
'ci.mysql', | ||
'ci.pgsql' | ||
] | ||
repo: [ | ||
'https://github.com/spryker-shop/b2b-demo-shop.git', | ||
'https://github.com/spryker-shop/b2c-demo-shop.git' | ||
] | ||
name: "Glue Tests(Image: ${{ matrix.platform-image }}, Environment: ${{ matrix.env }}, Repo: ${{ matrix.repo }})" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Clone demo shop | ||
run: cd ../ && git clone --depth=3 --branch=master ${{ matrix.repo }} demo-shop && cp -R docker-sdk demo-shop | ||
|
||
- name: Provide env variables | ||
run: | | ||
export SPRYKER_PLATFORM_IMAGE=${{ matrix.platform-image}} | ||
export APPLICATION_ENV=${{ matrix.env }} | ||
export APPLICATION_STORE=${{ matrix.application-store }} | ||
- name: Run script | ||
run: | | ||
cd ../demo-shop | ||
docker-sdk/sdk boot deploy.ci.api.yml -v | ||
docker-sdk/sdk up -t -v | ||
docker-sdk/sdk testing codecept fixtures | ||
docker-sdk/sdk testing console queue:worker:start --stop-when-empty | ||
docker-sdk/sdk testing codecept run -c codeception.api.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
name: Boot & Syntax check & tTests | ||
|
||
on: | ||
- push | ||
|
||
jobs: | ||
boot_test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
dev-mode: [ | ||
DEV_MODE=0, | ||
DEV_MODE=1 | ||
] | ||
name: Boot test | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Boot | ||
run: | | ||
export ${{ matrix.dev-mode }} | ||
chmod +x sdk | ||
if [[ $DEV_MODE == 0 ]] ; then ./sdk boot ci/deploy.yml; fi | ||
if [[ $DEV_MODE == 1 ]] ; then ./sdk boot ci/deploy.dev.yml; fi | ||
- name: Run script | ||
run: bash ./ci/check_boot.sh | ||
|
||
bash_syntax_check: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
dev-mode: [ | ||
DEV_MODE=0, | ||
DEV_MODE=1 | ||
] | ||
name: Bash syntax check | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Boot | ||
run: | | ||
export ${{ matrix.dev-mode }} | ||
chmod +x sdk | ||
if [[ $DEV_MODE == 0 ]] ; then ./sdk boot ci/deploy.yml; fi | ||
if [[ $DEV_MODE == 1 ]] ; then ./sdk boot ci/deploy.dev.yml; fi | ||
- name: Run script | ||
run: bash ./ci/check_boot.sh | ||
|
||
tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
dev-mode: [ DEV_MODE=0, DEV_MODE=1 ] | ||
name: Tests | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Boot | ||
run: | | ||
export ${{ matrix.dev-mode }} | ||
chmod +x sdk | ||
if [[ $DEV_MODE == 0 ]] ; then ./sdk boot ci/deploy.yml; fi | ||
if [[ $DEV_MODE == 1 ]] ; then ./sdk boot ci/deploy.dev.yml; fi | ||
- name: Run script | ||
run: bash ./ci/tests.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Deploy file builder tests | ||
|
||
on: | ||
- push | ||
|
||
jobs: | ||
deploy_file_builder_tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
php-version: [ 7.4 ] | ||
name: Deploy file builder tests | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup PHP with PECL extension | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: ${{ matrix.php-version }} | ||
|
||
- name: Run script | ||
run: | | ||
cd generator | ||
composer install | ||
vendor/bin/codecept run |
This file was deleted.
Oops, something went wrong.