Giter Club home page Giter Club logo

Comments (5)

stevenaw avatar stevenaw commented on June 9, 2024

@maettu-this Are you using .NET Framework or .NET Core for your project?
I see this same error as you when trying to run the InvertedTomato.Crc test suite itself on .NET Framework 4.8, which uses xunit. Removing the <PublicSign> there then also allows the net48 test target to work. The .NET7 target for the test suite works in either case.

You can see my branch here where I've added the new test runtime target and removed the <PublicSign> in separate commits
https://github.com/invertedtomato/crc/compare/master...stevenaw:crc:net48-test-target?expand=1

from nunit.

stevenaw avatar stevenaw commented on June 9, 2024

While I haven't found any documentation on it, I believe this could be a compatibility issue between .NET Framework and <PublicSign>. I've submitted this PR to InvertedTomato.Crc to try to fix the root issue: invertedtomato/crc#15

from nunit.

stevenaw avatar stevenaw commented on June 9, 2024

I found a write-up here: https://github.com/dotnet/runtime/blob/main/docs/project/public-signing.md and there are indeed some known issues on .NET Framework. Some of the scenarios like partial trust have since been removed in NUnit 4 so it's possible that it will work there but I haven't tested it

Known issues when debugging and testing public signed assemblies on .NET Framework:

  • You will not be able to install the assembly to the Global Assembly Cache (GAC)
  • You will not be able to load the assembly in an AppDomain where shadow copying is turned on.
  • You will not be able to load the assembly in a partially trusted AppDomain
  • You will not be able to pre-compile ASP.NET applications
  • You may not be able to load the assembly if the app.config file specifies //<NetFx40_LegacySecurityPolicy enabled="true" />

from nunit.

stevenaw avatar stevenaw commented on June 9, 2024

I'm going to close this.

I haven't been able to reproduce outside of the CRC repo where a fix for the issue itself has also now been fixed.
I've tried reproducing this on a standalone app using [email protected] and NUnit 3.14 consumed from NuGet and both net48 and net8 as TFMs and it seems to pass whether I sign the test assembly or not. I've run them both in Visual Studio and from CLI via dotnet test.

https://github.com/nunit/nunit.issues/tree/main/Issue4681

@maettu-this Can you please see if the latest merged PR to InvertedTomato.Crc helps you?

from nunit.

maettu-this avatar maettu-this commented on June 9, 2024

@stevenaw thanks for evaluating. And sorry for not responding earlier, been off for a week. And yes, I am still on .NET 4.8 for a bunch of reasons, where AppDomain migration is one of them.

I'll check again once a new release of InvertedTomato.Crc becomes available. If still an issue on .NET 4.8 I'll consider requesting separate builds of InvertedTomato.Crc for .NET Framework and .NET Standard 2.1+.

from nunit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.