-
Notifications
You must be signed in to change notification settings - Fork 154
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
ITestRunner.Run() does not pass Activity.Current to underlying test #1591
Comments
What happens if you use the 3.19 engine and api but vary the version of NUnit? |
results in a
|
Just recording a few notes: Change BOTH NUnit.Engine package versions to 3.18.3 (the release prior to 3.19.0) causes it to work properly.
Changing EITHER package to 3.19.0 causes it to break. |
There are not that many changes between 3.18.3...3.19.0 and there's nothing that sticks out obviously. This is removing support for a few things and changing the version of cake.tool from 4.0 to 5.0 so maybe there's a subtle difference in the versions that are loaded? Next step is to build a local copy of this with some additional logging because nothing stands out yet. |
@veleek Have you tried a |
Nope but that was my next plan. I’m a _little_ worried that it has
something to do with the SDK that it was built with so I wanted to verify
everything with released binaries first.
…On Sun, Mar 2, 2025 at 05:43 CharliePoole ***@***.***> wrote:
@veleek <https://github.com/veleek> Have you tried a git bisect to narrow
it down?
—
Reply to this email directly, view it on GitHub
<#1591 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIBSLJ7HOPAT6T4SX7RD7L2SMDI3AVCNFSM6AAAAABUR2O2YKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMOJSG42DAMJZGY>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
[image: CharliePoole]*CharliePoole* left a comment
(nunit/nunit-console#1591)
<#1591 (comment)>
@veleek <https://github.com/veleek> Have you tried a git bisect to narrow
it down?
—
Reply to this email directly, view it on GitHub
<#1591 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIBSLJ7HOPAT6T4SX7RD7L2SMDI3AVCNFSM6AAAAABUR2O2YKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMOJSG42DAMJZGY>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
After FAR too much work into this I've determined that there's a difference between There were a lot of project/framework/versioning changes around when I was working so I basically needed to nuke and rebuild everything each step and update Assembly Reference paths because a bunch of assembly build path changes happened around the same time period I was investigating. |
I've validated this as far back as 3.17.0 which produced both a netcoreapp3.1 binary (which fails) AND netcoreapp2.1 binary (which succeeds). |
We're calling specific tests programmatically through
ITestRunner.Run()
. In older versions ofNUnit.Engine
, theActivity.Current
that was started before the Run() call was available in the test, and we use this to pass some data (aTraceId
, to be specific).In the current version,
Activity.Current
is set tonull
inside the test, which breaks our implementations.Please see the attached zip file for a small C# project demonstrating the current, unexpected, behavior:
ActivityDebugging.zip
Replacing the packages with these older versions shows the Activity.Current set as expected:
The text was updated successfully, but these errors were encountered: