-
-
Notifications
You must be signed in to change notification settings - Fork 295
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
tests/plugins: refactor #235
Conversation
There is another option, we can have default.nix files for each subdirectories that would perform exactly the same work as the root file, i.e: Concat all the subfiles in a list with the path added to the name. I don't have any problems with the approach in this PR, but I don't know what you think @pta2002 |
You can have the automatic listing of the files and still support nesting. Just takes a bit more work, but not too much. I'd personally be more in favor of this since it avoids having to change the tests file every time |
Hmm I agree that it is feasible. I actually have already taken a look at this before submitting this PR. Anyway, if you feel like it is indeed better to support automatic nesting of nested folders, I can understand :) |
I think specifically in this case it's better than in the case of plugins. Picture this:
Now, imagine that you had to manually list it. What would the results be? The test just straight up would not run, because it's easy to forget to add to it, and it's really easy to miss without creating some automated rule for it... and at that point you might as well just auto-import it ;) This isn't as much of an issue with plugins because ideally you'd be testing it anyway and you'd catch it if you forgot to import it. |
I agree. It makes sense indeed ! |
Hi @pta2002 ! @traxys and I have been working to make this new proposal. Changes:
We are looking forward to your review, Best :) |
5127636
to
66a313c
Compare
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.
This looks very good, thanks for the work in this, and sorry for taking so long to look at it!
Thanks for the feedback :) |
In the existing version of the tests, all the files from the
tests/plugins/
folder are listed and imported.This was preventing us from structuring the content of this directory.
I removed this in favor of hard-coded imports (i.e. we explicitly list the test files we wish to import).
This allows for a conventional way of ordering the test cases.
I suggest that we keep the structure of the
tests/plugins/
folder exactly the same as the one of theplugins/
folder.