December 21, 2020
On Monday, 21 December 2020 at 11:31:49 UTC, drug wrote:
> [snip]
> Unfortunately I'm very busy. But I check it again and it turns out that the fix does not resolve the problem completely. This PR just remove the single file from testing so currently dub does not run unit tests in the single file package at all. The first variant (https://github.com/dlang/dub/pull/2050) fixes the issue indeed. I need to reevaluate these PRs and close the issue. I'll do it later.

Thanks for taking a look.
December 22, 2020
On 12/21/20 7:31 PM, jmh530 wrote:
> On Monday, 21 December 2020 at 11:31:49 UTC, drug wrote:
>> [snip]
>> Unfortunately I'm very busy. But I check it again and it turns out that the fix does not resolve the problem completely. This PR just remove the single file from testing so currently dub does not run unit tests in the single file package at all. The first variant (https://github.com/dlang/dub/pull/2050) fixes the issue indeed. I need to reevaluate these PRs and close the issue. I'll do it later.
> 
> Thanks for taking a look.

Not at all.

But what do you mean exactly by "work with dependency"? As I understand, `dub test` does not run unit tests in dependencies and single file packages work with dependencies in general. Do you mean something else? I'm finishing the new PR to fix #2051 finally and I'd like to know if there is something else I should include in it.
December 22, 2020
On 12/22/20 10:52 AM, drug wrote:
> On 12/21/20 7:31 PM, jmh530 wrote:
>> On Monday, 21 December 2020 at 11:31:49 UTC, drug wrote:
>>> [snip]
>>> Unfortunately I'm very busy. But I check it again and it turns out that the fix does not resolve the problem completely. This PR just remove the single file from testing so currently dub does not run unit tests in the single file package at all. The first variant (https://github.com/dlang/dub/pull/2050) fixes the issue indeed. I need to reevaluate these PRs and close the issue. I'll do it later.
>>
>> Thanks for taking a look.
> 
> Not at all.
> 
> But what do you mean exactly by "work with dependency"? As I understand, `dub test` does not run unit tests in dependencies and single file packages work with dependencies in general. Do you mean something else? I'm finishing the new PR to fix #2051 finally and I'd like to know if there is something else I should include in it.

https://github.com/dlang/dub/pull/2064
December 22, 2020
On Tuesday, 22 December 2020 at 15:06:09 UTC, drug wrote:
> [snip]
>> 
>> But what do you mean exactly by "work with dependency"? As I understand, `dub test` does not run unit tests in dependencies and single file packages work with dependencies in general. Do you mean something else? I'm finishing the new PR to fix #2051 finally and I'd like to know if there is something else I should include in it.
>
> https://github.com/dlang/dub/pull/2064

Thanks. It looks like your UT with taggedalgebraic does exactly what I was looking for.

My problem is that run.dlang.org will skip unittests when you have dependencies. I had made some progress on fixing this a few months ago [1], but put it on the back burner when I ran into similar issues that the OP was dealing with. The problem ultimately came down to dub test not working with --single, which it looks like this latest PR will fix for good.

[1] https://github.com/dlang-tour/core-exec/pull/56
December 23, 2020
On 12/22/20 8:32 PM, jmh530 wrote:
> On Tuesday, 22 December 2020 at 15:06:09 UTC, drug wrote:
>> [snip]
>>>
>>> But what do you mean exactly by "work with dependency"? As I understand, `dub test` does not run unit tests in dependencies and single file packages work with dependencies in general. Do you mean something else? I'm finishing the new PR to fix #2051 finally and I'd like to know if there is something else I should include in it.
>>
>> https://github.com/dlang/dub/pull/2064
> 
> Thanks. It looks like your UT with taggedalgebraic does exactly what I was looking for.
> 
> My problem is that run.dlang.org will skip unittests when you have dependencies. I had made some progress on fixing this a few months ago [1], but put it on the back burner when I ran into similar issues that the OP was dealing with. The problem ultimately came down to dub test not working with --single, which it looks like this latest PR will fix for good.
> 
> [1] https://github.com/dlang-tour/core-exec/pull/56

Ah, I see. Then I would say that `dub test` doesn't run unit tests from the main source file (where the main function is placed). And this is the reason, I guess. Now `dub test` runs unit tests from the main source file if the package is a single file one. I think that dependencies is irrelevant here, at least I didn't do anything special for them. Let's see what happens.
1 2
Next ›   Last »