Skip to content

Commit

Permalink
Temprorary shorten test.yml workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Pavel Abramov <[email protected]>
  • Loading branch information
uncleDecart committed Feb 1, 2024
1 parent 8e7598c commit 326bc34
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 193 deletions.
20 changes: 0 additions & 20 deletions .github/actions/run-eden-test/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,23 +26,3 @@ runs:
tpm_enabled: ${{ inputs.tpm_enabled }}
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}
- name: Run tests
run: EDEN_TEST_STOP=n ./eden test ./tests/workflow -s ${{ inputs.suite }} -v debug
shell: bash
working-directory: "./eden"
- name: Collect info
if: failure()
uses: ./eden/.github/actions/collect-info
- name: Collect logs
if: always()
uses: ./eden/.github/actions/publish-logs
with:
report_name: eden-report-${{ inputs.suite }}-tpm-${{ inputs.tpm_enabled }}-${{ inputs.file_system }}
- name: Clean up after test
if: always()
run: |
./eden stop
make clean
docker system prune -f -a
shell: bash
working-directory: "./eden"
71 changes: 6 additions & 65 deletions .github/actions/setup-environment/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,81 +16,22 @@ inputs:
runs:
using: 'composite'
steps:
- name: Setup go
uses: actions/setup-go@v3
with:
go-version: '1.18'
- name: Check
run: |
for addr in $(ip addr list|sed -En -e 's/.*inet ([0-9.]+).*/\1/p')
do
if echo "$addr" | grep -q -E "10.11.(12|13).[0-9]+"; then
echo "$addr overlaps with test"; exit 1
fi
done
df -h
sudo swapoff -a
free
shell: bash
working-directory: "./eden"
- name: Install Packages
run: |
sudo add-apt-repository ppa:stefanberger/swtpm-jammy
sudo apt install -y qemu-utils qemu-system-x86 jq swtpm util-linux
shell: bash
- name: Build tests
run: |
make build-tests
shell: bash
working-directory: "./eden"
- name: Configure
run: |
./eden config add default
if lscpu | grep -oEq "vmx|svm"; then
./eden config set default --key=eve.accel --value=true
else
./eden config set default --key=eve.accel --value=false
fi
./eden config set default --key=eve.tpm --value=${{ inputs.tpm_enabled }}
./eden config set default --key=eve.cpu --value=2
shell: bash
working-directory: "./eden"
- name: Download artifact if specified
if: inputs.eve_artifact_name != ''
uses: actions/download-artifact@v3
with:
name: $ {{ inputs.eve_artifact_name }}
path: artifacts # this is the directory where it will put the artifact, not its name
- name: list output of artifacts
run: |
ls -la artifacts
shell: bash
- name: Load containers to docker if specified
if: inputs.eve_artifact_name != ''
run: |
docker load -i artifacts/${{ inputs.eve_artifact_name }}.tar
docker image ls
shell: bash
- name: Setup eve version
- name: List Docker Images
run: |
image=${{ inputs.eve_image }}
if [[ -n "$image" && "$image" == *:* ]]; then
echo "Setting up eve image ${image}"
eve_pr_registry=$(echo "$image" | cut -d ':' -f 1)
eve_pr=$(echo "$image" | cut -d ':' -f 2 | cut -d "-" -f1)
./eden config set default --key=eve.registry --value="$eve_pr_registry"
./eden config set default --key=eve.tag --value="$eve_pr"
else
echo "Skipping setting up eve image ${image}"
fi
shell: bash
working-directory: "./eden"
- name: Setup ext4
if: inputs.file_system == 'ext4'
run: ./eden setup -v debug
shell: bash
working-directory: "./eden"
- name: Setup zfs
if: inputs.file_system == 'zfs'
run: |
./eden config set default --key=eve.disks --value=4
./eden config set default --key=eve.disk --value=4096
./eden setup -v debug --grub-options='set_global dom0_extra_args "$dom0_extra_args eve_install_zfs_with_raid_level "'
docker image ls
shell: bash
working-directory: "./eden"
108 changes: 0 additions & 108 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@ jobs:
smoke:
continue-on-error: true
strategy:
matrix:
file_system: ['ext4', 'zfs']
tpm: [true, false]
name: Smoke tests
needs: determine-runner
runs-on: ${{ needs.determine-runner.outputs.runner }}
Expand All @@ -53,107 +49,3 @@ jobs:
suite: "smoke.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

networking:
name: Networking test suite
needs: [smoke, determine-runner]
runs-on: ${{ needs.determine-runner.outputs.runner }}
steps:
- name: Get code
uses: actions/[email protected]
with:
repository: "lf-edge/eden"
path: "./eden"
- name: Run Networking tests
uses: ./eden/.github/actions/run-eden-test
with:
file_system: "ext4"
tpm_enabled: true
suite: "networking.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

storage:
continue-on-error: true
strategy:
matrix:
file_system: ['ext4', 'zfs']
name: Storage test suite
needs: [smoke, determine-runner]
runs-on: ${{ needs.determine-runner.outputs.runner }}
steps:
- name: Get code
uses: actions/[email protected]
with:
repository: "lf-edge/eden"
path: "./eden"
- name: Run Storage tests
uses: ./eden/.github/actions/run-eden-test
with:
file_system: ${{ matrix.file_system }}
tpm_enabled: true
suite: "storage.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

lpc-loc:
name: LPC LOC test suite
needs: [smoke, determine-runner]
runs-on: ${{ needs.determine-runner.outputs.runner }}
steps:
- name: Get code
uses: actions/[email protected]
with:
repository: "lf-edge/eden"
path: "./eden"
- name: Run LPC LOC tests
uses: ./eden/.github/actions/run-eden-test
with:
file_system: "ext4"
tpm_enabled: true
suite: "lpc-loc.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

eve-upgrade:
continue-on-error: true
strategy:
matrix:
file_system: ['ext4', 'zfs']
name: EVE upgrade test suite
needs: [smoke, determine-runner]
runs-on: ${{ needs.determine-runner.outputs.runner }}
steps:
- name: Get code
uses: actions/[email protected]
with:
repository: "lf-edge/eden"
path: "./eden"
- name: Run EVE upgrade tests
uses: ./eden/.github/actions/run-eden-test
with:
file_system: ${{ matrix.file_system }}
tpm_enabled: true
suite: "eve-upgrade.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

user-apps:
name: User apps test suite
needs: [smoke, determine-runner]
runs-on: ${{ needs.determine-runner.outputs.runner }}
steps:
- name: Get code
uses: actions/[email protected]
with:
repository: "lf-edge/eden"
path: "./eden"
- name: Run User apps upgrade tests
uses: ./eden/.github/actions/run-eden-test
with:
file_system: "ext4"
tpm_enabled: true
suite: "user-apps.tests.txt"
eve_image: ${{ inputs.eve_image }}
eve_artifact_name: ${{ inputs.eve_artifact_name }}

0 comments on commit 326bc34

Please sign in to comment.