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

CI: Test with newer RabbitMQ versions #6419

Merged
merged 3 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from 2 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
68 changes: 64 additions & 4 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ concurrency:

jobs:

tests:
nightly-tests:

if: github.repository == 'aiidateam/aiida-core' # Prevent running the builds on forks as well
runs-on: ubuntu-latest
Expand Down Expand Up @@ -76,9 +76,9 @@ jobs:
run: .github/workflows/tests_nightly.sh

- name: Slack notification
# Always run this step (otherwise it would be skipped if any of the previous steps fail) but only if the
# `install` or `tests` steps failed, and the `SLACK_WEBHOOK` is available. The latter is not the case for
# pull requests that come from forks. This is a limitation of secrets on GHA
# Always run this step (otherwise it would be skipped if any of the previous steps fail) but only if the
# `install` or `tests` steps failed, and the `SLACK_WEBHOOK` is available. The latter is not the case for
# pull requests that come from forks. This is a limitation of secrets on GHA
if: always() && (steps.install.outcome == 'Failure' || steps.tests.outcome == 'Failure') && env.SLACK_WEBHOOK != null
uses: rtCamp/action-slack-notify@v2
env:
Expand All @@ -88,3 +88,63 @@ jobs:
SLACK_COLOR: b60205
SLACK_TITLE: Nightly build of `aiida-core/main` failed
SLACK_MESSAGE: The tests of the `nightly.yml` GHA worklow failed.


# Run a subset of test suite to ensure compatibility with latest RabbitMQ releases
rabbitmq_tests:

runs-on: ubuntu-latest
timeout-minutes: 30

strategy:
fail-fast: false
matrix:
# Currently supported RMQ versions per:
# https://www.rabbitmq.com/docs/which-erlang#compatibility-matrix
rabbitmq-version: ['3.11', '3.12', '3.13']

services:
postgres:
image: postgres:16
danielhollas marked this conversation as resolved.
Show resolved Hide resolved
env:
POSTGRES_DB: test_aiida
POSTGRES_PASSWORD: ''
POSTGRES_HOST_AUTH_METHOD: trust
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
rabbitmq:
image: rabbitmq:${{ matrix.rabbitmq-version }}-management
ports:
- 5672:5672
- 15672:15672

steps:
- uses: actions/checkout@v4

- name: Install aiida-core
uses: ./.github/actions/install-aiida-core

- name: Install system dependencies
run: sudo apt update && sudo apt install postgresql

- name: Run tests
run: pytest -sv -k 'requires_rmq'

- name: Slack notification
# Always run this step (otherwise it would be skipped if any of the previous steps fail) but only if the
# `install` or `tests` steps failed, and the `SLACK_WEBHOOK` is available. The latter is not the case for
# pull requests that come from forks. This is a limitation of secrets on GHA
if: always() && (steps.install.outcome == 'Failure' || steps.tests.outcome == 'Failure') && env.SLACK_WEBHOOK != null
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_ICON: https://www.materialscloud.org/discover/images/0ba0a17d.aiida-logo-128.png
SLACK_CHANNEL: dev-aiida-core
SLACK_COLOR: b60205
SLACK_TITLE: RabbitMQ nightly tests of `aiida-core/main` failed
SLACK_MESSAGE: The rabbitmq tests in the `nightly.yml` GHA worklow failed.
58 changes: 0 additions & 58 deletions .github/workflows/rabbitmq.yml

This file was deleted.

Loading