Skip to content

[Feature - NOKIA] Controller multiprocessing, time chunking, cache safety, tracking improvements #8007

[Feature - NOKIA] Controller multiprocessing, time chunking, cache safety, tracking improvements

[Feature - NOKIA] Controller multiprocessing, time chunking, cache safety, tracking improvements #8007

Workflow file for this run

---
# SPDX-FileCopyrightText: (C) 2025 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
name: "[Tests] Basic Acceptance Tests"
run-name: "[Tests] Basic Acceptance Tests"
on:
workflow_dispatch:
inputs:
cleanup:
description: "Cleanup before running BAT tests"
required: false
default: false
type: boolean
timeout:
description: "Timeout for the job in minutes"
required: false
type: number
default: 60
pull_request:
branches:
- main
- release-*
types:
- opened
- synchronize
- reopened
- ready_for_review
push:
branches:
- main
- release-*
# Trigger workflow when enqueued to a merge group
# (must be under 'on')
merge_group: {}
# Only run at most 1 workflow concurrently per PR or per branch to keep costs down
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
DOCKER_BUILDKIT: 1
SUPASS: demo
permissions:
contents: read
jobs:
check-pr-state:
name: "Check PR State"
runs-on: ubuntu-latest
outputs:
pr_state: ${{ steps.check_pr.outputs.pr_state }}
steps:
- name: "Return success if triggered manually"
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
echo "Triggered manually."
exit 0
- name: Checkout code
if: ${{ github.event_name == 'pull_request' }}
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: "Set up GitHub CLI"
if: ${{ github.event_name == 'pull_request' }}
run: |
sudo apt-get update && sudo apt-get install gh
- name: "Check PR state"
id: check_pr
if: ${{ github.event_name == 'pull_request' }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER=${{ github.event.number }}
PR_STATE=$(gh pr view $PR_NUMBER --json isDraft --jq '.isDraft')
echo "pr_state=$PR_STATE" >> $GITHUB_OUTPUT
echo "PR State \"isDraft\": $PR_STATE"
filter:
name: "Filter Changed Code Paths"
needs: check-pr-state
runs-on: ubuntu-latest
if: ${{ needs.check-pr-state.outputs.pr_state != 'true' || github.event_name == 'workflow_dispatch' }}
outputs:
code_changed: ${{ steps.filter.outputs.code }}
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Set paths filter
id: filter
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
with:
predicate-quantifier: "every"
filters: |
code:
- '!**/*.md'
- '!**/*.rst'
- '!**/*.html'
- '!**/*.license'
- '!**/*.svg'
- '!**/*.png'
- '!**/*.jpeg'
- '!**/*.jpg'
- '!**/*.JPG'
- '!**/*.ico'
- '!**/*.pdf'
- '!LICENSES/**'
- '!docs/**'
run-basic-acceptance-tests:
name: "Run Basic Acceptance Tests"
runs-on: [bat]
timeout-minutes: ${{ fromJSON(inputs.timeout || '60') }}
needs: [filter, check-pr-state]
if: ${{ needs.filter.outputs.code_changed == 'true' && (needs.check-pr-state.outputs.pr_state != 'true' || github.event_name == 'workflow_dispatch') }}
steps:
- name: "Checkout Repository"
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: "Remove all Docker images"
if: ${{ github.event.inputs.cleanup == 'true' }}
uses: ./.github/actions/cleanup
with:
system-prune: "true"
- name: "Run Basic Acceptance Tests (BAT)"
run: |
make clean-all
git clean -fdx
make run_basic_acceptance_tests
- name: "Run Basic Acceptance Tests (BAT) - k8s"
run: |
make clean-all
git clean -fdx
make run_basic_acceptance_tests_k8s SUPASS=change_me KUBERNETES=1
- name: Rename logs to remove colons
if: always()
run: |
set +e # Ignore errors if no logs are found
find . -wholename "**/test_data/**/*.log" -exec rename 's/:/-/g' {} +
exit 0
- name: Upload Test Reports
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 #v4.6.2
with:
name: tests-reports
path: |
tests/**/test_reports/**/*.html
tests/**/test_reports/**/*.xml
- name: Upload Test Logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 #v4.6.2
with:
name: tests-logs
path: |
**/test_data/**/*.log
- name: Cleanup
if: always()
uses: ./.github/actions/cleanup
chart-deployment-test:
name: "Chart Deployment Test"
runs-on: [bat]
needs: [filter, check-pr-state]
if: ${{ needs.filter.outputs.code_changed == 'true' && (needs.check-pr-state.outputs.pr_state != 'true' || github.event_name == 'workflow_dispatch') }}
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0
- name: Set up Helm
uses: azure/setup-helm@1a275c3b69536ee54be43f2070a358922e12c8d4 # v4.3.1
- uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0
with:
python-version: "3.x"
check-latest: true
- name: Install chart with timeout
run: KUBERNETES=1 DEPLOYMENT_TEST=1 ./deploy.sh
- name: Print all pods
if: always()
run: kubectl get pods,deployments,services -n scenescape -o wide
- name: Cleanup
if: always()
uses: ./.github/actions/cleanup