Skip to content

Commit

Permalink
X
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiasblaesing committed Feb 23, 2024
1 parent 85efcac commit aaded86
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions contrib/platform/test/com/sun/jna/platform/mac/IOKitTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,8 @@ public void testMatching() {
String serialNumberViaUtil = platformExpert.getStringProperty("IOPlatformSerialNumber");
assertEquals(serialNumber, serialNumberViaUtil);

assertEquals(12, serialNumber.length());
assertTrue("Known serial number lengths are 10 and 12, was: " + serialNumber.length(),
serialNumber.length() == 12 || serialNumber.length() == 10);
// Get all the keys
dict = platformExpert.createCFProperties();
assertNotEquals(0, dict.getValueIfPresent(serialKey, null));
Expand Down Expand Up @@ -214,7 +215,7 @@ public void testIOConnect() {
int masterPort = IOKitUtil.getMasterPort();

IOService smcService = IOKitUtil.getMatchingService("AppleSMC");
assertNotNull(smcService);
assumeTrue(smcService != null); // Service is not available on github M1 runners

PointerByReference connPtr = new PointerByReference();
int taskSelf = SYS.mach_task_self();
Expand Down

0 comments on commit aaded86

Please sign in to comment.