-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
To work around an issue in pytest, run tests from empty temp dir #1566
To work around an issue in pytest, run tests from empty temp dir #1566
Conversation
Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. 🤞 |
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_30 ran successfully. |
ebff1bd
to
b37b0da
Compare
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_30 ran successfully. |
Create empty temporary directory to run "pytest" command from to work-around an issue in pytest accessing files/directories it may not have access to during test collection. pytest-dev/pytest#11904
b37b0da
to
4441b9f
Compare
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_30 ran successfully. |
Creating an empty sub-directory within working directory and running pytest from there as suggested in pytest-dev/pytest#11904 did not work on Windows.
Notice that pytest reports "rootdir" as that empty temporary directory, yet it still attempts to traverse "C:\Documents and Settings" and got PermissionError. So, giving up, I have pushed a change to use "pytest'<8'" when installing pytest in conda environment. |
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_31 ran successfully. |
a253a0a
to
b7a07fa
Compare
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_31 ran successfully. |
b7a07fa
to
b961b1a
Compare
Array API standard conformance tests for dpctl=0.17.0dev0=py310h15de555_31 ran successfully. |
- name: Run tests | ||
shell: cmd /C CALL {0} | ||
env: | ||
SYCL_CACHE_PERSISTENT: 1 | ||
working-directory: ${{ env.workdir }}\test_tmp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would allow default path, since it should also in writable location (how would conda install
else work)? So conda environment location is located in writable path. Putting conda env in working folder could result in accidental removal and unexpected CI behavior. Same for other job.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, but this newly created folder is writable too. It is created by the workflow at the prior step as a sub-folder of the default path.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGMT! Just small nit.
Create empty temporary directory to run "pytest" command from to work-around an issue in pytest accessing files/directories it may not have access to during test collection.
pytest-dev/pytest#11904
This should fixed test_windows step failures.