-
Notifications
You must be signed in to change notification settings - Fork 110
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
--------- Signed-off-by: Alina Buzachis <[email protected]> Co-authored-by: Abhijeet Kasurde <[email protected]>
- Loading branch information
1 parent
94a3a71
commit 858f415
Showing
34 changed files
with
673 additions
and
574 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,3 +68,4 @@ testuser | |
toxinidir | ||
trustore | ||
truststore | ||
testpass |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
name: Run integration tests | ||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- labeled | ||
- unlabeled | ||
- synchronize | ||
branches: | ||
- main | ||
- stable-* | ||
schedule: | ||
- cron: '0 */8 * * *' | ||
|
||
jobs: | ||
integration-tests: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
python-version: | ||
- "3.11" | ||
ansible-version: | ||
- "milestone" | ||
|
||
steps: | ||
- name: Checkout ansible/eda | ||
uses: actions/checkout@v3 | ||
with: | ||
path: ansible_collections/ansible/eda | ||
ref: ${{ github.event.pull_request.head.sha }} | ||
fetch-depth: "0" | ||
|
||
- name: Checkout ansible/eda-server | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: ansible/eda-server | ||
path: eda-server # Note: Specify a separate path for this repository | ||
|
||
- name: Run API in background | ||
run: | | ||
docker compose -p eda -f docker-compose-stage.yaml pull | ||
docker compose -p eda -f docker-compose-stage.yaml up -d | ||
until curl -s http://localhost:8000/_healthz | grep -q "OK"; do | ||
echo "Waiting for API to be ready..." | ||
sleep 1 | ||
done | ||
working-directory: eda-server/tools/docker # Adjusted to the specific directory where docker-compose.yaml is located | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install ansible-core (${{ matrix.ansible-version }}) | ||
run: >- | ||
python3 -m pip install | ||
https://github.com/ansible/ansible/archive/${{ matrix.ansible-version }}.tar.gz | ||
--disable-pip-version-check | ||
shell: bash | ||
|
||
- name: Print the ansible version | ||
run: ansible --version | ||
|
||
- name: Create integration_config.yml | ||
run: | | ||
touch tests/integration/integration_config.yml | ||
echo "controller_host: 'https://localhost:8443'" >> tests/integration/integration_config.yml | ||
echo "controller_username: 'admin'" >> tests/integration/integration_config.yml | ||
echo "controller_password: 'testpass'" >> tests/integration/integration_config.yml | ||
echo "controller_verify_ssl: false" >> tests/integration/integration_config.yml | ||
working-directory: ansible_collections/ansible/eda | ||
|
||
- name: Run integration tests | ||
run: ansible-test integration -v | ||
working-directory: ansible_collections/ansible/eda |
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
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
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
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
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
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
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
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
Oops, something went wrong.