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

Project is not detected when running from REPL #23

Open
ktdq opened this issue Sep 7, 2022 · 4 comments
Open

Project is not detected when running from REPL #23

ktdq opened this issue Sep 7, 2022 · 4 comments
Labels
enhancement New feature or request

Comments

@ktdq
Copy link

ktdq commented Sep 7, 2022

@run_package_tests and run_tests fail to detect current project when run from REPL and all tests fail. Can Pkg.project() be used in this case?

@davidanthoff
Copy link
Member

So, the idea is that you just put @run_package_tests into your test/runtests.jl file, but not call it directly. From the REPL you would either go into REPL mode and just run ] test or run Pkg.test("MyPackage") or something like that. And that should all work, right?

@ktdq
Copy link
Author

ktdq commented Sep 7, 2022

This all works, but I was trying to run tests for one folder only, not all tests.

@davidanthoff davidanthoff added the enhancement New feature or request label Sep 7, 2022
@davidanthoff
Copy link
Member

Ah, yes, that is not yet supported here. We'll need a generic filtering mechanism, and I first want to add support for tags and then I was thinking I would try to tackle filtering from the command line. My rough idea is that you might be able to do something like

TestItemRunner.test(packagename, filter=i -> :tag1 in i.tags)

or something like that. i would presumably also give access to the name and file location of a given test item.

@davidanthoff
Copy link
Member

Oh, but you should be able to run the tests in a specific folder/file in the VS Code UI, of course.

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

No branches or pull requests

2 participants