mirror of
https://github.com/iruletheworldmo/strawberry.git
synced 2024-08-13 23:12:55 -05:00
add github actions to test agi
This commit is contained in:
parent
53b3b7fdfc
commit
bfc51128d1
1 changed files with 25 additions and 0 deletions
25
.github/workflows/test.yaml
vendored
Normal file
25
.github/workflows/test.yaml
vendored
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
on:
|
||||||
|
pull_request
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Run AGI for 5s
|
||||||
|
run: |
|
||||||
|
set +e
|
||||||
|
|
||||||
|
timeout 5s python3 strawberry.py
|
||||||
|
exit_code=$?
|
||||||
|
|
||||||
|
if [ $exit_code -eq 124 ]; then
|
||||||
|
echo "Key Interrupt (timeout) - Success"
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
echo "Unexpected exit code: $exit_code"
|
||||||
|
exit 1
|
||||||
|
fi
|
Loading…
Reference in a new issue