Build/Test Issues

NUnit 3 and OneTimeSetUpAttribute

Started by TURNSKIN on 10,291 views

Hi,
I'm using NCrunch 2.16.0.13 with NUnit.3.0.0-beta-4
We introduced Parallelizable attritube with OneTimeSetUp
NCrunch runs all new test as expected, but do not run method with OneTimeSetUp attribute

check attached screenshot. You can see white dots near method "FixtureSetup"

Screenshot: OneTimeSetUp

How can I this this?

Edited

Hi, thanks for posting.

Right now NCrunch doesn't yet support the new NUnit (NUnit 3). This is a major revision of NUnit that is still under development and will require significant work to support. NCrunch will add support for this framework soon.
Has this been resolved yet? I am still seeing this issue in 2.27.

Also would be beneficial to know if there is a way to run a test setup per assembly, e.g. database creation.
Hi Remco,

My OneTimeSetup module is not being called.

This worked about 2 weeks ago. I did upgrade to newer versions of NUnit and ASP.NET Framework in the last two weeks or so.

NCrunch 3.9.01.
NUnit 3.7.1
NUnit 3 Test Adapter 3.7.0
VS 2017 Community Edition

One suggestion I saw to solve the problem of OneTimeSetup not being called is to install NUint 3 Test Adapter. I installed 3.7.0. That didn't fix anything.

Thanks, Ed
Hi Ed,

Thanks for sharing this problem. Are you able to share any code that I might be able to use to reproduce it? Presently all NCrunch tests around this are passing, so it may be a use case that I haven't been tracking.

Usually this sort of thing is all handled internally within NUnit. Does the OneTimeSetup module work correctly under a different test runner?

Post a reply

Log in to reply.