unoplatform / uno.ui.runtimetests.engine

In-App MS Tests Runner for Uno Platform and WinAppSDK
https://platform.uno/
Other
7 stars 3 forks source link

0.24.0-dev.95 only works with release builds #152

Closed mrlacey closed 8 months ago

mrlacey commented 8 months ago

Current behavior

For a solution using 0.24.0-dev.95 Any test project that references another project, it looks for a NuGet package source in a path relative to the referenced project and in a \Release directory.

Expected behavior

It should not do anything dependeny on the type of build. I should be able to build test projects and execute tests in debug mode without first having to do a local release build!

How to reproduce it (as minimally and precisely as possible)

Internal Uno project available for repro/test if needed.

Environment

Nuget Package:

Uno.UI.RuntimeTests.Engine

Package Version(s):

0.24.0-dev.95

Affected platform(s):

Visual Studio:

Relevant plugins:

Anything else we need to know?

Did this happen because any CI checks run as Release but developers often work in Debug mode and build and run tests in this mode?

jeromelaban commented 8 months ago

/cc @dr1rrb

dr1rrb commented 8 months ago

Hummmm ... weird, contacted you in private for the repro :)

mrlacey commented 8 months ago

Trying different versions. The last version that works is 0.19.0-dev.82

dr1rrb commented 8 months ago

Ok so I tried with your project and indeed I got some package restore issue :

error NU1507: Warning As Error: There are 2 package sources defined in your configuration. When using central package management, please map your package sources with package source mapping (https://aka.ms/nuget-package-source-mapping) or specify a single package source. The following sources are defined: nuget.org, Unoplatform stagging

Disabling the "Uno staging" nuget feed in VS settings fixed the issue on my side.

The weird thing is that this the Uno.UI.RuntimeTests.Engine package is not even present on the "staging feed" and it doesn't have any dependency :/

dr1rrb commented 8 months ago

So according to @jeromelaban, you should only ignore (nowarn) NU1507 in your project / solution

mrlacey commented 8 months ago

So, I'm going to assume a NuGet-related issue that somehow only happens when using the package. :/

I've since seen a similar issue in completely different solutions (and not using anything Uno related). Not a bug here.