summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBruce Forstall <brucefo@microsoft.com>2015-09-15 11:31:37 -0700
committerBruce Forstall <brucefo@microsoft.com>2015-09-15 11:31:37 -0700
commit235d807ed6012590241a8e21433a257df7de264a (patch)
tree8e6d6c7d1494fd8666e90a0c98f3bddfff8d97c1 /tests
parent2bc5657bd796e78d33aff45c7137b92b821d3a93 (diff)
parent396373adde3ea53f136ac99f7e9e1936811b3e9c (diff)
downloadcoreclr-235d807ed6012590241a8e21433a257df7de264a.tar.gz
coreclr-235d807ed6012590241a8e21433a257df7de264a.tar.bz2
coreclr-235d807ed6012590241a8e21433a257df7de264a.zip
Merge pull request #1540 from BruceForstall/FixPow1TestForLinux
Fix pow1 test to run on Linux
Diffstat (limited to 'tests')
-rw-r--r--tests/src/JIT/Directed/intrinsic/pow/pow1.cs15
1 files changed, 7 insertions, 8 deletions
diff --git a/tests/src/JIT/Directed/intrinsic/pow/pow1.cs b/tests/src/JIT/Directed/intrinsic/pow/pow1.cs
index 4fffad9233..ef7cfd4aae 100644
--- a/tests/src/JIT/Directed/intrinsic/pow/pow1.cs
+++ b/tests/src/JIT/Directed/intrinsic/pow/pow1.cs
@@ -16,19 +16,18 @@ internal class pow1
//Check if the test is being executed on ARM
bool isProcessorArm = false;
+ string processorArchEnvVar = null;
+
#if CORECLR
- if (TestLibrary.Env.GetEnvVariable("PROCESSOR_ARCHITECTURE").Equals(
- "ARM", StringComparison.CurrentCultureIgnoreCase))
- {
- isProcessorArm = true;
- }
+ processorArchEnvVar = TestLibrary.Env.GetEnvVariable("PROCESSOR_ARCHITECTURE");
#else
- if (Environment.GetEnvironmentVariable("PROCESSOR_ARCHITECTURE").Equals(
- "ARM", StringComparison.CurrentCultureIgnoreCase))
+ processorArchEnvVar = Environment.GetEnvironmentVariable("PROCESSOR_ARCHITECTURE");
+#endif
+
+ if ((processorArchEnvVar != null) && processorArchEnvVar.Equals("ARM", StringComparison.CurrentCultureIgnoreCase))
{
isProcessorArm = true;
}
-#endif
x = 0;
y = 0;