Skip to content

Commit

Permalink
CI: Switch to Makefile for running acceptance tests
Browse files Browse the repository at this point in the history
We can remove the 'acceptancetest' script in the process. Note that this
isn't a 1:1 match: the fwaasv2 test job now runs the entire networking
test suite and not just the fwaasv2-specific tests but seeing as this is
using OVS rather than OVN that doesn't seem like such a bad thing.

Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
  • Loading branch information
stephenfin committed May 15, 2024
1 parent 5de8acf commit 6104d02
Show file tree
Hide file tree
Showing 20 changed files with 25 additions and 79 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/functional-baremetal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-baremetal
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: '^.*baremetal(.(?!noauth).*)?$'
OS_BRANCH: ${{ matrix.openstack_version }}
# TODO(dtantsur): default to "all" when no longer supporting versions before 2024.1
OS_SYSTEM_SCOPE: ${{ matrix.os_system_scope }}
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-basic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-basic
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: '^internal/acceptance/openstack$'
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-blockstorage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-blockstorage
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: ^.*blockstorage(.(?!noauth).*)?$
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-clustering.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-clustering
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*clustering.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-compute.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-compute
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*compute.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-containerinfra.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-containerinfra
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*containerinfra.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-dns.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-dns
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^acceptance/openstack/dns.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-fwaas_v2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-networking
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*fwaas_v2.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-identity.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-identity
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*identity.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-image
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*image.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-keymanager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-keymanager
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*keymanager.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-loadbalancer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-loadbalancer
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*loadbalancer.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-messaging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-messaging
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*messaging.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-networking.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-networking
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^(?!.*fwaas_v2.*).*networking.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-objectstorage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-objectstorage
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: '^.*objectstorage.*$'
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-orchestration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-orchestration
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: ^.*orchestration.*$
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-placement.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-placement
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: ^.*placement.*$
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/functional-sharedfilesystems.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,9 @@ jobs:
with:
go-version: '^1.20'
- name: Run Gophercloud acceptance tests
run: ./script/acceptancetest
run: make acceptance-sharedfilesystem
env:
DEVSTACK_PATH: ${{ github.workspace }}/devstack
ACCEPTANCE_TESTS_FILTER: "^.*sharedfilesystems.*$"
OS_BRANCH: ${{ matrix.openstack_version }}
- name: Generate logs on failure
run: ./script/collectlogs
Expand Down
8 changes: 7 additions & 1 deletion internal/acceptance/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,13 @@ to set them manually.
From the root directory, run:

```
./script/acceptancetest
make acceptance
```

You can also run tests for a specific service:

```
make acceptance-compute
```

Alternatively, add the following to your `.bashrc`:
Expand Down
42 changes: 0 additions & 42 deletions script/acceptancetest

This file was deleted.

0 comments on commit 6104d02

Please sign in to comment.