<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <!--
   Nunit-agent only runs under .NET 2.0 or higher. 
   The setting    useLegacyV2RuntimeActivationPolicy only applies 
   under .NET 4.0 and permits use of mixed mode assemblies, 
   which would otherwise not load correctly. 
  -->
  <startup useLegacyV2RuntimeActivationPolicy="true">
    <!--
     Nunit-agent is normally run by the console or gui
     runners and not independently. In normal usage, 
     the runner specifies which runtime should be used.
     
     Do NOT add any supportedRuntime elements here, 
     since they may prevent the runner from controlling 
     the runtime that is used!
    -->
  </startup>

  <runtime>
    <!-- Ensure that test exceptions don't crash NUnit -->
    <legacyUnhandledExceptionPolicy enabled="1" />

    <!--
     Since legacyUnhandledExceptionPolicy keeps the console from being killed even though an NUnit framework
     test worker thread is killed, this is needed to prevent a hang. NUnit framework can only handle these
     exceptions when this config element is present. (Or if future versions of NUnit framework drop support
     for partial trust which would enable it to use [HandleProcessCorruptedStateExceptions].)
    -->
    <legacyCorruptedStateExceptionsPolicy enabled="true" />

    <!-- Run partial trust V2 assemblies in full trust under .NET 4.0 -->
    <loadFromRemoteSources enabled="true" />

    <!-- Enable reading source information from Portable and Embedded PDBs when running applications -->
    <!-- built against previous .NET Framework versions on .NET Framework 4.7.2 -->
    <AppContextSwitchOverrides value="Switch.System.Diagnostics.IgnorePortablePDBsInStackTraces=false" />
  </runtime>
  
</configuration>
