public static void TraceCurrentRollbarInfrastructureConfig() { RollbarUnitTestEnvironmentUtil.Trace( RollbarInfrastructure.Instance.Config, "ROLLBAR_INFRASTRUCTURE_CONFIG:" ); }
public static void SetupLiveTestRollbarInfrastructure() { SynchronizationContext.SetSynchronizationContext(new SynchronizationContext()); var config = RollbarUnitTestEnvironmentUtil.GetLiveTestRollbarInfrastructureConfig(); if (!RollbarInfrastructure.Instance.IsInitialized) { RollbarInfrastructure.Instance.Init(config); } else { RollbarInfrastructure.Instance.Config.Reconfigure(config); } RollbarUnitTestEnvironmentUtil.TraceCurrentRollbarInfrastructureConfig(); }
public static void Trace(object content, string title = null) { string contentAsString; ITraceable tracable = content as ITraceable; if (tracable != null) { contentAsString = tracable.TraceAsString(); } else if (content != null) { contentAsString = content.ToString(); } else { contentAsString = "<null>"; } RollbarUnitTestEnvironmentUtil.Trace(contentAsString, title); }
public static RollbarInfrastructureConfig GetLiveTestRollbarInfrastructureConfig() { var config = new RollbarInfrastructureConfig(); var destinationOptions = RollbarUnitTestEnvironmentUtil.GetLiveTestRollbarDestinationOptions(); config .RollbarLoggerConfig .RollbarDestinationOptions .Reconfigure(destinationOptions); var infrastructureOptions = new RollbarInfrastructureOptions(); infrastructureOptions.PayloadPostTimeout = TimeSpan.FromSeconds(3); config .RollbarInfrastructureOptions .Reconfigure(infrastructureOptions); return(config); }
public static void Trace(string content, string title = null) { Debug.WriteLine(RollbarUnitTestEnvironmentUtil.Decorate(content, title)); //Debug.WriteLine(string.Empty); }