1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-14 10:13:05 +02:00
pgbackrest/.github/workflows/test.yml
David Steele c32e000ab9 Use Rocky Linux for documentation builds instead of CentOS.
Since CentOS 8 will be EOL at the end of the year it makes sense to do this now. The centos:8 image is still used in documentation.xml because changes there require manual testing, which will need to be done at a later date. The changes are not user-facing, however, and can be done at any time.

Also update CentOS references to RHEL since that is what we are emulating for testing purposes.
2021-10-28 15:15:49 -04:00

89 lines
2.4 KiB
YAML

name: test
on:
push:
branches:
- integration
- '**-ci'
- '**-cig'
pull_request:
branches:
- integration
- '**-ci'
- '**-cig'
jobs:
test:
runs-on: ubuntu-18.04
strategy:
# Let all the jobs run to completion even if one fails
fail-fast: false
# The first jobs should be the canaries in the coal mine, i.e. the most likely to fail if there are problems in the code. They
# should also be a good mix of unit, integration, and documentation tests.
#
# In general tests should be ordered from slowest to fastest. This does not make a difference for testing a single commit, but
# when multiple commits are being tested it is best to have the slowest jobs first so that as jobs become available they will
# tackle the slowest tests first.
matrix:
include:
# All unit (without coverage) and integration tests for 32-bit
- param: test --vm=d9 --param=no-performance
# Debian/Ubuntu documentation
- param: doc --vm=u18
# All integration tests
- param: test --vm=u20 --param=build-package --param=module=mock --param=module=real
# All unit tests (with coverage) on the newest gcc available
- param: test --vm=f33 --param=c-only --param=tz=America/New_York
# RHEL documentation
- param: doc --vm=rh8
# All integration tests
- param: test --vm=rh7 --param=module=mock --param=module=real
steps:
- name: Checkout Code
uses: actions/checkout@v2
with:
path: pgbackrest
- name: Run Test
run: cd ${HOME?} && ${GITHUB_WORKSPACE?}/pgbackrest/test/ci.pl ${{matrix.param}} --param=build-max=2
codeql:
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language:
- cpp
steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Install Packages
run: sudo apt-get install -y --no-install-recommends libyaml-dev
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{matrix.language}}
- name: Build
run: ${GITHUB_WORKSPACE?}/src/configure && make -j 2
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1