2 writes to _originalState
System.Private.Windows.Core.TestUtilities (2)
AppContextSwitchScope.cs (2)
34if (!AppContext.TryGetSwitch(switchName, out _originalState)) 36_originalState = getDefaultValue is not null && getDefaultValue();
3 references to _originalState
System.Private.Windows.Core.TestUtilities (3)
AppContextSwitchScope.cs (3)
50AppContext.SetSwitch(_switchName, _originalState); 51if (!AppContext.TryGetSwitch(_switchName, out bool isEnabled) || isEnabled != _originalState) 53throw new InvalidOperationException($"Could not reset {_switchName} to {_originalState}.");