Skip to content

[CI] Update workflow script, ensure functional test determinism, fix coverage tests. #1

[CI] Update workflow script, ensure functional test determinism, fix coverage tests.

[CI] Update workflow script, ensure functional test determinism, fix coverage tests. #1

Workflow file for this run

# .github/workflows/create-container-unit-tests.yml
name: Unit Tests
env:
REPORT_ADDR: http://120.92.110.224:8081
on:
workflow_call:
inputs:
backend:
required: true
type: string
subset:
required: true
type: string
jobs:
unit-test:
runs-on: ubuntu-latest
# container:
# image: localhost:5000/flagscale_cicd:v1.5
# ports:
# - 80
# volumes:
# - /home/flagscale_cicd/flask/static:/workspace/report
# - /home/flagscale_cicd/docker/docker_build/docker_data:/home/gitlab-runner/data
# - /home/flagscale_cicd/docker/docker_build/docker_tokenizers:/home/gitlab-runner/tokenizers
# options: --gpus all --shm-size=500g --hostname flagscale_cicd
steps:

Check failure on line 29 in .github/workflows/unit-tests.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/unit-tests.yml

Invalid workflow file

You have an error in your yaml syntax on line 29
- name: Checkout Code
uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
fetch-depth: 0
- name: Create and switch to branch
run: |
git checkout -b temp_branch
- name: Display current branch and HEAD
run: |
echo "Current branch:"
git branch --show-current
echo "HEAD points to:"
git rev-parse HEAD
# - name: Run Unit Tests and Check Coverage
# run: |
# tests/scripts/unit_tests/test_coverage_online.sh --backend ${{ inputs.backend }} --id ${{ github.sha }}
# - name: Run Unit Test
# run: tests/scripts/unit_tests/test_subset.sh --backend ${{ inputs.backend }} --subset ${{ inputs.subset }} --id ${{ github.sha }}
# - name: Unit Test Coverage Online Report
# run: echo "You can access the test coverage report at the $REPORT_ADDR/${{github.sha}}/cov-report-${{ inputs.backend }}/index.html"