xmos / lib_xud

XMOS USB code and associated examples
Other
8 stars 25 forks source link

add pytest to jenkins #328

Closed kevinyeungxmos closed 2 years ago

xross commented 2 years ago

@danielpieczko any idea on this please?

xross commented 2 years ago

I guess we need to run build in test_support

kevinyeungxmos commented 2 years ago

I guess we need to run build in test_support

@danielpieczko Does jenkins possible to add Pyxsim and xcoverage to PYTHONPATH ?

danielpieczko commented 2 years ago

@danielpieczko Does jenkins possible to add Pyxsim and xcoverage to PYTHONPATH ?

You can set environment variables in the "environment" block near the start of the Jenkinsfile. If you want to add directories to the PYTHONPATH, you should be able to add something like: PYTHONPATH = env.PYTHONPATH:<pyxsim_dir>:<xcoverage_dir>

I hope that works, but I've never tried extending an environment variable in this way on Jenkins before.

Is there a reason why they can't be added to requirements.txt so that they are automatically built and installed?

xross commented 2 years ago

adding -e ../test_support should fix it?

kevinyeungxmos commented 2 years ago

-e ../test_support/lib/python

I'll try it

xross commented 2 years ago

setup.py is in the root of test_support, so I think it would just be -e ../test_support

Had just spotted that and edited.. :)

danielpieczko commented 2 years ago

setup.py is in the root of test_support, so I think it would just be -e ../test_support

Had just spotted that and edited.. :)

And I spotted your edit and deleted mine :)

xross commented 2 years ago

Looks like we have one test fail that passes locally. I'd like to be able to see the logs.

I think we just need to add:

xross commented 2 years ago

Interesting half the tests start to fail now tracing is enabled

kevinyeungxmos commented 2 years ago

Interesting half the tests start to fail now tracing is enabled

change --numprocesses=4 passed

xross commented 2 years ago

Interesting half the tests start to fail now tracing is enabled

change --numprocesses=4 passed

Thanks odd, simulator timeout should be based on xcore cycles. Great its working though