Adiciona configuração retroativo #105
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
name: Build | |
on: | |
push: | |
branches: | |
- main | |
- develop | |
- sonar/teste | |
- release-sonar | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
test-unit: | |
name: Test Unit & Scan | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Test Unit | |
id: test-unit | |
run: | | |
docker-compose -f docker-compose.test.yml up -V --force-recreate --build --abort-on-container-exit --exit-code-from gerocuidado-forum-api-test | |
env: | |
TEST: unit | |
- name: SonarCloud Scan | |
uses: SonarSource/sonarcloud-github-action@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
- name: Sincroniza cobertura de testes com o Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
fail_ci_if_error: true | |
flags: jest | |
name: 2023-2-GEROcuidado-APIForum | |
verbose: true | |
test-e2e: | |
name: Test E2E | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Test E2E | |
id: test-e2e | |
run: | | |
docker-compose -f docker-compose.test.yml up -V --force-recreate --build --abort-on-container-exit --exit-code-from gerocuidado-forum-api-test | |
env: | |
TEST: e2e |