Skip to content

Commit

Permalink
Move python test code into seperate env var
Browse files Browse the repository at this point in the history
  • Loading branch information
PucklaJ committed Feb 16, 2024
1 parent 2444399 commit 3042b4e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push]

env:
TEST_CASES: d3_buffer_seek,_get_nth_digit,_insert_sorted,d3_word_binary_search,Array,glob,string_builder,Array::New,binout_directory,path_move_up,path_join,path_is_abs,path_view,extra_string,card_parse_get_type,empty_card,profiling,sync,multi_file
CREATE_PYTHON_SYMLINK_LINUX: ln -s build/linux/x86_64/release/dynareadout.cpython-311-x86_64-linux-gnu.so $HOME/.local/lib/python3.11/site-packages/dynareadout.cpython-311-x86_64-linux-gnu.so
PYTHON_TEST_CODE: 'import dynareadout as dro\ntry:\n\tb = dro.Binout("test")\nexcept RuntimeError as e:\n\tif str(e) != "test: No files have been found":\n\t\texit(1)\n\telse:\n\t\tprint("Success")\n'

jobs:
linux-x86_64-static:
Expand Down Expand Up @@ -60,7 +60,7 @@ jobs:
- run: xmake f -yvD -p linux -a x86_64 -k static -m release --build_python=y
- run: xmake -wvD
- run: ls -la --color=always build/linux/x86_64/release
- run: cd build/linux/x86_64/release && printf 'import dynareadout as dro\ntry:\n\tb = dro.Binout("hello")\nexcept RuntimeError as e:\n\tprint(e)\n' | python
- run: cd build/linux/x86_64/release && printf $PYTHON_TEST_CODE && printf $PYTHON_TEST_CODE | python


windows-x64-static:
Expand Down

0 comments on commit 3042b4e

Please sign in to comment.