Skip to content
Merged
Show file tree
Hide file tree
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
10 changes: 7 additions & 3 deletions .github/workflows/atex-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,14 @@ jobs:
- name: Install test dependencies
run: |
dnf -y install python3-pip rsync
pip install fmf atex==0.12
pip install fmf atex==0.13

- name: Run tests on Testing Farm
env:
TESTING_FARM_API_TOKEN: ${{ secrets.TESTING_FARM_API_TOKEN }}
CS_MAJOR: ${{ matrix.centos_stream_major }}
REPO_URL: ${{ github.server_url }}/${{ github.repository }}
ACTOR: ${{ github.actor }}
run: |
python3 tests/run_tests_testingfarm.py \
--contest-dir contest \
Expand All @@ -157,7 +159,9 @@ jobs:
--compose "CentOS-Stream-${CS_MAJOR}" \
--arch x86_64 \
--os-major-version "${CS_MAJOR}" \
--timeout ${{ env.TEST_TIMEOUT }}
--timeout ${{ env.TEST_TIMEOUT }} \
--tag github_actor=$ACTOR \
--tag github_repo=$REPO_URL

- name: Upload test results
if: always()
Expand Down Expand Up @@ -186,7 +190,7 @@ jobs:
if: always()
run: |
dnf -y install python3-pip git rsync
pip install fmf atex==0.12
pip install fmf atex==0.13

- name: Checkout ATEX results repository
if: always()
Expand Down
7 changes: 7 additions & 0 deletions tests/run_tests_testingfarm.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@
logger = logging.getLogger("ATEX")


def kv_pair(keyval):
if "=" not in keyval:
raise argparse.ArgumentTypeError(f"expected KEY=VALUE, got: {keyval}")
return keyval.split("=", 1)

def parse_args():
"""Parse command-line arguments."""
parser = argparse.ArgumentParser(description="Run tests on Testing Farm using atex")
Expand All @@ -33,6 +38,7 @@ def parse_args():
parser.add_argument("--timeout", type=int, default=120, help="Timeout in minutes")
parser.add_argument("--max-remotes", type=int, default=10, help="Maximum number of parallel test executions")
parser.add_argument("--reruns", type=int, default=1, help="Number of test reruns on failure")
parser.add_argument("--tag", type=kv_pair, default=[], action="append", help="Additional tag(s) to store in TF Request")
return parser.parse_args()


Expand Down Expand Up @@ -116,6 +122,7 @@ def main():
arch=args.arch,
max_retries=2,
timeout=args.timeout,
tags=dict(args.tag),
)

# Setup Contest orchestrator
Expand Down
Loading