Closed viceroypenguin closed 1 day ago
Struggling to recreate with your code. Must be some race condition or something 🤔
Try:
public class BaseClass;
[ClassConstructor<DummyClassConstructor>]
[NotInParallel]
public sealed class Dummy : BaseClass
{
[Test]
public void Step1()
{
throw new NotImplementedException();
}
[Test]
[DependsOn(nameof(Step1))]
public void Step2()
{
}
[Test]
[DependsOn(nameof(Step2))]
public void Step3()
{
}
}
public class DummyClassConstructor : IClassConstructor
{
public T Create<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] T>(ClassConstructorMetadata classConstructorMetadata) where T : class
{
if (typeof(T) != typeof(Dummy))
throw new NotImplementedException();
return (T)(object)new Dummy();
}
}
Still the same for me! Can you confirm it still happens on 0.2.202?
I would, except now VS cannot run the tests; either it spends 2+ minutes trying to find tests before I cancel it, or it runs Step1/Step2 and never completes either of them. I can confirm that running the project under 0.2.195 gave me two fails and one pass, while 0.2.202 gives me three fails, as expected.
The latest version has broken Visual Studio for you?
The latest version has broken Visual Studio for you?
Yes. Was fine under 0.2.195, broken on 0.2.202
@viceroypenguin Can you reproduce it? My test explorer is working fine on the latest version.
Yes. This is what happens currently in VS 17.12 preview 5:
Can you try 0.2.208?
Yes, 0.2.208 works correctly. Thanks!
Check the following code:
Expected:
Step2
will fail sinceStep1
did not succeeed.Actual:
Step2
passes, butStep3
fails becauseStep1
has failed.