Sha256: 5e377e5bfbe97fd4e5a3c1741e02de45265d44b5d83243a92ab30e75b13d10a5

Contents?: true

Size: 402 Bytes

Versions: 5

Compression:

Stored size: 402 Bytes

Contents

using System.Collections.Generic;
using System.Linq;

namespace Generators.Output
{
    public class ExceptionTestMethodGenerator : TestMethodGenerator
    {
        protected override IEnumerable<string> Body => Variables.Append($"Assert.Throws<{ExceptionType}>(() => {TestedMethodInvocation});");
        
        private string ExceptionType => CanonicalDataCase.ExceptionThrown.FullName;
    }
}

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
trackler-2.1.0.53 tracks/csharp/generators/Output/ExceptionTestMethodGenerator.cs
trackler-2.1.0.52 tracks/csharp/generators/Output/ExceptionTestMethodGenerator.cs
trackler-2.1.0.51 tracks/csharp/generators/Output/ExceptionTestMethodGenerator.cs
trackler-2.1.0.50 tracks/csharp/generators/Output/ExceptionTestMethodGenerator.cs
trackler-2.1.0.49 tracks/csharp/generators/Output/ExceptionTestMethodGenerator.cs