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

Working directory when running tests is VS Code #28

Open
korbinian90 opened this issue Oct 6, 2022 · 1 comment
Open

Working directory when running tests is VS Code #28

korbinian90 opened this issue Oct 6, 2022 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@korbinian90
Copy link

The working directory when running a @testset via the vs code UI is "C:\Users\korbi\AppData\Local\Programs\Microsoft VS Code".
The default julia package test runs in "test" inside the package being tested.

This makes it complicated to reference data in the repository used for testing purposes.
If the path working directory would be identical, @testset could simply be replaced with @testitem.

Otherwise, this is an amazing feature! The tests run instantly!

@korbinian90
Copy link
Author

Solved this for now for my use case:

@testitem "test" begin
cd(@__DIR__)
load_data("data/small")
...

You can keep this open or close it as you prefer ;)

@davidanthoff davidanthoff added the bug Something isn't working label Oct 15, 2022
@davidanthoff davidanthoff self-assigned this Oct 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants