abelsiqueira / BestieTemplate.jl

Template for Julia Programming Language packages using the copier engine.
http://abelsiqueira.com/BestieTemplate.jl/
Mozilla Public License 2.0
38 stars 9 forks source link

[extras] test section vs test/Project.toml #408

Open oxinabox opened 1 month ago

oxinabox commented 1 month ago

Description

There are two ways to specify tests dependencies test/Project.toml and the [extras] section with targets=test.

I prefer the later as it makes it impossible to get incompatible versions between tests and main dependencies, and harder to have duplicates. Further technically the test/Project.toml is kinda experimental (see the note here) "The exact interaction ... are not fully worked out and may be subject to change in future versions" and the original developer of that feature is no longer contributing.

Currently BestieTemplates.jl does the former. I believe PkgTemplates.jl lets you chose, and by default does the later.

abelsiqueira commented 4 weeks ago

Yeah, I was under the impression that test/Project.toml would become the norm, but it does seem to have stalled. A developer leaving explains a lot.

It makes sense to me to have a separate environment for the test like the docs, but indeed, it lacks tooling to have it working nicely. I will have to look into this with more detail to have an opinion on changing the default.

Having it as an option is surely possible.

mmikhasenko commented 3 weeks ago

I always used [targets] test=, and discovered the way of test/Projects.toml with the BestieTemplate.

What I noticed is that test/Projects.toml takes the preference by julia: in case test/Projects.toml exists, [targets] test= is ignored.