summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSung Yoon Whang <suwhang@microsoft.com>2018-03-16 11:56:24 -0700
committerGitHub <noreply@github.com>2018-03-16 11:56:24 -0700
commitd6b2ead7f821e06b8e7bdc4a82812d1cfbc732ac (patch)
treeb6a6b30dbc245c6e9f8e4fcfc2551e5d5fc1d50c /tests
parentdf996e2e64a88463169f523a2b5542730116b4fb (diff)
downloadcoreclr-d6b2ead7f821e06b8e7bdc4a82812d1cfbc732ac.tar.gz
coreclr-d6b2ead7f821e06b8e7bdc4a82812d1cfbc732ac.tar.bz2
coreclr-d6b2ead7f821e06b8e7bdc4a82812d1cfbc732ac.zip
Fix test for GC.GetAllocatedBytesForCurrentThread to be more lenient with the accuracy (#16976)
Diffstat (limited to 'tests')
-rwxr-xr-xtests/src/GC/API/GC/GetAllocatedBytesForCurrentThread.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/src/GC/API/GC/GetAllocatedBytesForCurrentThread.cs b/tests/src/GC/API/GC/GetAllocatedBytesForCurrentThread.cs
index 89a1904685..3922c27718 100755
--- a/tests/src/GC/API/GC/GetAllocatedBytesForCurrentThread.cs
+++ b/tests/src/GC/API/GC/GetAllocatedBytesForCurrentThread.cs
@@ -89,7 +89,7 @@ public class Test
nBytesAfter = (long)method.Invoke(null, null);
- if (((nBytesBefore + 16) != nBytesAfter) && ((nBytesBefore + 24) != nBytesAfter))
+ if (nBytesAfter == nBytesBefore) // Shouldn't be the same
{
int countAfter = GC.CollectionCount(0);
Console.WriteLine("b: {0}, a: {1}, iter {2}, {3}->{4}", nBytesBefore, nBytesAfter, i, countBefore, countAfter);