digitalmars.D.learn - Dub and unit-threaded import problem
- Casey (31/31) Mar 05 2016 Hello,
- Atila Neves (3/8) Mar 05 2016 You mispelled "dependencies".
- Casey (2/12) Mar 05 2016 Thanks. I knew it had to be something dumb.
- Casey (3/13) Mar 05 2016 Oh, and forgot to mention I like what you did with this new
- Sebastiaan Koppe (18/29) Mar 05 2016 If dub is complaining about not finding bin/ut.d, You need a
Hello,
I'm just starting a small project with dub and unit-threaded, but
I'm getting an issue where the file "unit_threaded.d" cannot be
found.
Details:
DMD version: DMD64 2.070.0
Dub version: 0.9.24
Dub Config:
{
"name": "pst",
"targetType": "executable",
"targetPath": "bin",
"configurations": [
{
"name": "unittest",
"preBuildCommands": [
"dub run unit-threaded -c gen_ut_main -- -f
bin/ut.d"
],
"mainSourceFile": "bin/ut.d",
"excludedSourceFiles": ["source/app.d"],
"dependences": {
"unit-threaded": "~>0.6.3"
}
}
]
}
I haven't created any tests at this time. It's a bare project.
I just wanted to make sure the dub config worked before I started
coding. I feel I'm missing something very simple. I just don't
see it.
Mar 05 2016
On Saturday, 5 March 2016 at 15:05:50 UTC, Casey wrote:Hello, I'm just starting a small project with dub and unit-threaded, but I'm getting an issue where the file "unit_threaded.d" cannot be found. [...]You mispelled "dependencies". Atila
Mar 05 2016
On Saturday, 5 March 2016 at 18:01:48 UTC, Atila Neves wrote:On Saturday, 5 March 2016 at 15:05:50 UTC, Casey wrote:Thanks. I knew it had to be something dumb.Hello, I'm just starting a small project with dub and unit-threaded, but I'm getting an issue where the file "unit_threaded.d" cannot be found. [...]You mispelled "dependencies". Atila
Mar 05 2016
On Saturday, 5 March 2016 at 18:01:48 UTC, Atila Neves wrote:On Saturday, 5 March 2016 at 15:05:50 UTC, Casey wrote:Oh, and forgot to mention I like what you did with this new update of unit-threaded. Can't wait to get some code written.Hello, I'm just starting a small project with dub and unit-threaded, but I'm getting an issue where the file "unit_threaded.d" cannot be found. [...]You mispelled "dependencies". Atila
Mar 05 2016
On Saturday, 5 March 2016 at 15:05:50 UTC, Casey wrote:
{
"name": "unittest",
"preBuildCommands": [
"dub run unit-threaded -c gen_ut_main -- -f bin/ut.d"
],
"mainSourceFile": "bin/ut.d",
"excludedSourceFiles": ["source/app.d"],
"dependences": {
"unit-threaded": "~>0.6.3"
}
}
If dub is complaining about not finding bin/ut.d, You need a
"importPaths": ["bin"] in there. Dub by default only looks in the
source folder, and it cannot find `bin/ut.d` in `./source`. If
that is the case you also need to remove the `source` part from
the excludedSourceFiles.
Here is a config that works for me
{
"name": "unittest",
"preBuildCommands": ["dub run unit-threaded -c gen_ut_main --
-f bin/ut.d"],
"importPaths": ["bin"],
"mainSourceFile": "bin/ut.d",
"excludedSourceFiles": ["app.d"],
"dependencies": {
"unit-threaded": "~>0.6.3"
}
}
Mar 05 2016









Casey <sybrandy gmail.com> 