Skip to content

Commit a906600

Browse files
committed
Moved properties from the Runtime class that are only used by the unit tests.
1 parent 0fa1735 commit a906600

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

src/Magick.NET/Helpers/Runtime.cs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,5 @@ internal static partial class Runtime
1010
{
1111
public static bool Is64Bit { get; } = IntPtr.Size == 8;
1212

13-
public static bool IsArm64 { get; } = RuntimeInformation.ProcessArchitecture == Architecture.Arm64;
14-
15-
public static bool IsLinux { get; } = RuntimeInformation.IsOSPlatform(OSPlatform.Linux);
16-
17-
public static bool IsMacOS { get; } = RuntimeInformation.IsOSPlatform(OSPlatform.OSX);
18-
1913
public static bool IsWindows { get; } = RuntimeInformation.IsOSPlatform(OSPlatform.Windows);
2014
}
Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
11
// Copyright Dirk Lemstra https://github.com/dlemstra/Magick.NET.
22
// Licensed under the Apache License, Version 2.0.
33

4-
using ImageMagick;
4+
using System.Runtime.InteropServices;
55

66
namespace Magick.NET.Tests;
77

88
internal static class TestRuntime
99
{
1010
public static bool HasFlakyLinuxArm64Result
11-
=> Runtime.IsLinux && Runtime.IsArm64;
11+
=> IsLinux && IsArm64;
1212

1313
public static bool HasFlakyMacOSResult
14-
=> Runtime.IsMacOS;
14+
=> IsMacOS;
1515

1616
public static bool HasFlakyMacOSArm64Result
17-
=> Runtime.IsMacOS && Runtime.IsArm64;
17+
=> IsMacOS && IsArm64;
18+
19+
private static bool IsArm64 { get; } = RuntimeInformation.ProcessArchitecture == Architecture.Arm64;
20+
21+
private static bool IsLinux { get; } = RuntimeInformation.IsOSPlatform(OSPlatform.Linux);
22+
23+
private static bool IsMacOS { get; } = RuntimeInformation.IsOSPlatform(OSPlatform.OSX);
1824
}

0 commit comments

Comments
 (0)