Skip to content

Commit cb1a907

Browse files
committed
ci: add subprocess demo tests to regression gate
Signed-off-by: danbugs <danilochiarlone@gmail.com>
1 parent 0159b3e commit cb1a907

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/test-examples.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -946,6 +946,32 @@ jobs:
946946
exit 1
947947
}
948948
949+
- name: pyhl run (busybox subprocess demo)
950+
if: runner.os == 'Windows' || steps.kvm_check.outputs.available == 'true'
951+
shell: pwsh
952+
run: |
953+
$out = pyhl run examples/python-agent-driver/demo_busybox.py 2>&1
954+
Write-Host $out
955+
if ($out -match 'hello from hyperlight guest') {
956+
Write-Host "PASS: busybox subprocess demo"
957+
} else {
958+
Write-Error "FAIL: did not match /hello from hyperlight guest/"
959+
exit 1
960+
}
961+
962+
- name: pyhl run (pip install subprocess demo)
963+
if: runner.os == 'Windows' || steps.kvm_check.outputs.available == 'true'
964+
shell: pwsh
965+
run: |
966+
$out = pyhl run --net examples/python-agent-driver/demo_pip_install.py 2>&1
967+
Write-Host $out
968+
if ($out -match 'Installed and imported six') {
969+
Write-Host "PASS: pip install subprocess demo"
970+
} else {
971+
Write-Error "FAIL: did not match /Installed and imported six/"
972+
exit 1
973+
}
974+
949975
test-examples-passed:
950976
if: always()
951977
needs:

0 commit comments

Comments
 (0)