Пример #1
0
        public void CanSetCrashReportingLevelForDynatrace()
        {
            // given
            var target = new DynatraceOpenKitBuilder(Endpoint, AppID, DeviceID);

            // when
            var level    = CrashReportingLevel.OPT_IN_CRASHES;
            var obtained = target.WithCrashReportingLevel(level);
            var config   = target.BuildConfiguration().BeaconConfig;

            // then
            Assert.That(obtained, Is.InstanceOf <DynatraceOpenKitBuilder>());
            Assert.That((DynatraceOpenKitBuilder)obtained, Is.SameAs(target));
            Assert.That(config.CrashReportingLevel, Is.EqualTo(level));
        }
 /// <summary>
 /// Set the crash reporting level
 ///
 /// <list type="bullet">
 /// <item>
 /// <description><see cref="OpenKit.CrashReportingLevel.OFF"/> Crashes are not sent to the server</description>
 /// </item>
 /// <item>
 /// <description><see cref="OpenKit.CrashReportingLevel.OPT_OUT_CRASHES"/> Crashes are not sent to the server</description>
 /// </item>
 /// <item>
 /// <description><see cref="OpenKit.CrashReportingLevel.OPT_IN_CRASHES"/> Crashes are sent to the server</description>
 /// </item>
 /// </list>
 ///
 /// Default value: <see cref="OpenKit.CrashReportingLevel.OPT_IN_CRASHES"/>
 /// </summary>
 /// <param name="crashReportingLevel"></param>
 /// <returns><code>this</code></returns>
 public DynatraceOpenKitBuilderVB WithCrashReportingLevel(CrashReportingLevel crashReportingLevel)
 {
     wrappedBuilder.WithCrashReportingLevel(crashReportingLevel);
     return(this);
 }