File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
test/Libraries/Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests/Windows Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change 1+ // Licensed to the .NET Foundation under one or more agreements.
2+ // The .NET Foundation licenses this file to you under the MIT license.
3+
4+ using Microsoft . Extensions . Diagnostics . ResourceMonitoring . Windows . Interop ;
5+ using Microsoft . TestUtilities ;
6+ using Xunit ;
7+
8+ namespace Microsoft . Extensions . Diagnostics . ResourceMonitoring . Windows . Test ;
9+
10+ /// <summary>
11+ /// Process Info Interop Tests.
12+ /// </summary>
13+ /// <remarks>These tests are added for coverage reasons, but the code doesn't have
14+ /// the necessary environment predictability to really test it.</remarks>
15+ [ OSSkipCondition ( OperatingSystems . Linux | OperatingSystems . MacOSX , SkipReason = "Windows specific." ) ]
16+ public sealed class ProcessInfoTests
17+ {
18+ [ ConditionalFact ]
19+ public void GetCurrentProcessMemoryUsage ( )
20+ {
21+ var workingSet64 = new ProcessInfo ( ) . GetCurrentProcessMemoryUsage ( ) ;
22+ Assert . True ( workingSet64 > 0 ) ;
23+ }
24+ }
You can’t perform that action at this time.
0 commit comments