Exemplo n.º 1
0
    static DisableDirScrubbingTests()
    {
        VerifierSettings.DontScrubSolutionDirectory();
        VerifierSettings.DontScrubProjectDirectory();
        var solutionDirectory = AttributeReader.GetSolutionDirectory();

        VerifierSettings.AddScrubber(s => s.Replace(solutionDirectory, "CustomReplace\\"));
    }
Exemplo n.º 2
0
 public static void Initialize()
 {
     VerifierSettings.ModifySerialization(settings =>
     {
         settings.AddExtraSettings(serializerSettings =>
         {
             var converters = serializerSettings.Converters;
             converters.Add(new ProcessResultConverter());
             converters.Add(new SnippetConverter());
         });
     });
     VerifierSettings.AddScrubber(Scrubber.Scrub);
 }
 public static void Initialize()
 {
     VerifierSettings.AddScrubber(x => x.RemoveLineSuffix("boundary="));
     VerifierSettings.ModifySerialization(settings =>
     {
         settings.IgnoreMember <ExecutionResult>(result => result.Perf);
         settings.IgnoreMember <ExecutionResult>(result => result.Document);
         settings.IgnoreMember <ExecutionResult>(result => result.Operation);
         settings.AddExtraSettings(serializerSettings =>
         {
             serializerSettings.Converters.Add(new AttachmentConverter());
             serializerSettings.Converters.Add(new QueryResultConverter());
         });
     });
 }
Exemplo n.º 4
0
    public static void Initialize()
    {
        VerifyNServiceBus.Enable();
        var nsbVersion       = FileVersionInfo.GetVersionInfo(typeof(Endpoint).Assembly.Location);
        var nsbVersionString = $"{nsbVersion.FileMajorPart}.{nsbVersion.FileMinorPart}.{nsbVersion.FileBuildPart}";

        VerifierSettings.IgnoreStackTrace();
        VerifierSettings.AddScrubber(x => x.Replace(nsbVersionString, "NsbVersion"));
        VerifierSettings.ScrubMachineName();
        VerifierSettings.AddExtraSettings(_ =>
        {
            _.Converters.Add(new LogEventPropertyConverter());
            _.Converters.Add(new LogEventConverter());
            _.Converters.Add(new ScalarValueConverter());
            _.Converters.Add(new PropertyEnricherConverter());
        });
        VerifierSettings.AddExtraDatetimeOffsetFormat("yyyy-MM-dd HH:mm:ss:ffffff Z");
    }
Exemplo n.º 5
0
    public static void Initialize()
    {
        var nsbVersion       = FileVersionInfo.GetVersionInfo(typeof(Endpoint).Assembly.Location);
        var nsbVersionString = $"{nsbVersion.FileMajorPart}.{nsbVersion.FileMinorPart}.{nsbVersion.FileBuildPart}";

        VerifierSettings.ScrubLinesContaining("StackTraceString");
        VerifierSettings.ScrubLinesContaining("NServiceBus.TimeSent");
        VerifierSettings.ScrubLinesContaining("HandlerStartTime");
        VerifierSettings.ScrubLinesContaining("HandlerFailureTime");
        VerifierSettings.AddScrubber(x => x.Replace(nsbVersionString, "NsbVersion"));
        VerifierSettings.ScrubMachineName();
        VerifierSettings.ModifySerialization(settings =>
        {
            settings.AddExtraSettings(newtonsoft =>
            {
                newtonsoft.Converters.Add(new LogEventPropertyConverter());
                newtonsoft.Converters.Add(new LogEventConverter());
                newtonsoft.Converters.Add(new ScalarValueConverter());
            });
        });
        VerifierSettings.AddExtraDatetimeFormat("yyyy-MM-dd HH:mm:ss:ffffff Z");
    }
Exemplo n.º 6
0
 static ScrubberLevelsSample()
 {
     // Should be dont at appdomain startup
     VerifierSettings.AddScrubber(s => s.Replace("One", "A"));
 }
Exemplo n.º 7
0
 public static void Setup(TestContext testContext)
 {
     VerifierSettings.AddScrubber(s => s.Replace("One", "A"));
 }
Exemplo n.º 8
0
 public static void Initialize()
 {
     VerifierSettings.AddScrubber(_ => _.Replace("String to verify", "new value"));
 }
Exemplo n.º 9
0
 public static void Initialize()
 {
     VerifierSettings.AddScrubber(s => s.Replace("One", "A"));
 }
 public static void All()
 {
     VerifierSettings.AddScrubber("html", Scrubber);
     VerifierSettings.AddScrubber("htm", Scrubber);
 }