Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix integration tests #1419

Closed
wants to merge 4 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 39 additions & 53 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ env:
on:
push:
branches:
- 'master'
- '*'
tags:
- 'v[0-9]+.[0-9]+.[0-9]+([0-9]+)'
pull_request:
branches:
- 'master'
- '*'

jobs:
linting:
Expand Down Expand Up @@ -78,45 +78,45 @@ jobs:
uses: docker/build-push-action@v5
with:
context: .

# temporarily comment out to get GH action into place. Will fix tests on a follow on PR.
# https://github.com/Sceptre/sceptre/pull/1412#discussion_r1452566731
# integration-tests:
# needs:
# - unit-tests
# if: ${{ github.event_name != 'pull_request' }}
# runs-on: ubuntu-latest
# permissions:
# id-token: write
# steps:
# - uses: actions/checkout@v4
# - name: Install Poetry
# uses: snok/install-poetry@v1
# - name: Install dependencies
# run: poetry install --no-interaction --all-extras
# # Update poetry for https://github.com/python-poetry/poetry/issues/7184
# - name: update poetry
# run: poetry self update --no-ansi
# - name: Setup Python
# id: setup-python
# uses: actions/setup-python@v5
# with:
# python-version: '3.10'
# cache: 'poetry'
# - name: Assume AWS role
# uses: aws-actions/configure-aws-credentials@v4
# with:
# aws-region: ${{ env.AWS_REGION }}
# role-to-assume: ${{ env.AWS_ROLE }}
# role-session-name: GHA-${{ github.repository_owner }}-${{ github.event.repository.name }}-${{ github.run_id }}
# role-duration-seconds: ${{ env.AWS_ROLE_DURATION }}
# - name: run tests
# run: poetry run behave integration-tests/features --junit --junit-directory build/behave

docker-build-push:
integration-tests:
needs:
- linting
- packaging
- documentation
- unit-tests
- docker-build
if: ${{ github.ref == 'refs/heads/master' }}
if: ${{ github.ref_type == 'push' }}
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/checkout@v4
- name: Install Poetry
uses: snok/install-poetry@v1
- name: Install dependencies
run: poetry install --no-interaction --all-extras
# Update poetry for https://github.com/python-poetry/poetry/issues/7184
- name: update poetry
run: poetry self update --no-ansi
- name: Setup Python
id: setup-python
uses: actions/setup-python@v5
with:
python-version: '3.10'
cache: 'poetry'
- name: Assume AWS role
uses: aws-actions/configure-aws-credentials@v4
with:
aws-region: ${{ env.AWS_REGION }}
role-to-assume: ${{ env.AWS_ROLE }}
role-session-name: GHA-${{ github.repository_owner }}-${{ github.event.repository.name }}-${{ github.run_id }}
role-duration-seconds: ${{ env.AWS_ROLE_DURATION }}
- name: run tests
run: AWS_DEFAULT_REGION=eu-west-1 poetry run behave integration-tests/features --junit --junit-directory build/behave
docker-build-push:
needs:
- integration-tests
if: ${{ (github.ref_type == 'push') && (github.ref == 'refs/heads/master') }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -136,13 +136,6 @@ jobs:
tags: sceptreorg/sceptre:${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
docker-build-release:
needs:
- linting
- packaging
- documentation
- unit-tests
- docker-build
# - integration-tests
if: ${{ github.ref_type == 'tag' }}
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -170,13 +163,6 @@ jobs:
tags: sceptreorg/sceptre:${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
pypi-release:
needs:
- linting
- packaging
- documentation
- unit-tests
- docker-build
# - integration-tests
if: ${{ github.ref_type == 'tag' }}
runs-on: ubuntu-latest
steps:
Expand Down