Skip to content
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

Symlinks not replicated in temporary directory #1

Closed
gtristan opened this issue Jan 2, 2018 · 3 comments
Closed

Symlinks not replicated in temporary directory #1

gtristan opened this issue Jan 2, 2018 · 3 comments

Comments

@gtristan
Copy link

gtristan commented Jan 2, 2018

I'm using pytest-datafiles to test BuildStream, which is a build tool and as such does a lot of filesystem manipulation (naturally, we also have a lot of test cases which need to manipulate files mirrored outside of the git directory).

For us, the difference between a symlink to a file, and a copy of the said file, is an important difference; we need to test build scenarios where there are symlinks.

Currently our problem is that, if I commit symlinks to my test data dirs in git, and then use @pytest.mark.datafiles() to test with a directory that contains symlinks, the symlinks just dont appear in the test environment. Instead copies of the symlink targets are created.

Currently I have some ugly workarounds in place which create the required symlinks in the tmpdir manually in advance of testing.

@omarkohl
Copy link
Owner

omarkohl commented Jan 3, 2018

Thanks for the feedback! I'll have a look.

@omarkohl
Copy link
Owner

omarkohl commented Oct 7, 2018

Sorry it took me a while, but it should be fixed now. You can try it with the current 'master' branch or wait for the next release which will probably happen today or the next few days.

@omarkohl
Copy link
Owner

omarkohl commented Oct 7, 2018

This has been released with pytest-datafiles version 2.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants