1
2
3
4
5 package oshi.driver.unix.solaris.disk;
6
7 import static org.hamcrest.MatcherAssert.assertThat;
8 import static org.hamcrest.Matchers.anEmptyMap;
9 import static org.hamcrest.Matchers.is;
10 import static org.hamcrest.Matchers.not;
11
12 import java.util.Map;
13
14 import org.junit.jupiter.api.Test;
15 import org.junit.jupiter.api.condition.EnabledOnOs;
16 import org.junit.jupiter.api.condition.OS;
17
18 import oshi.util.tuples.Quintet;
19
20 @EnabledOnOs(OS.SOLARIS)
21 class DiskDriversTest {
22 @Test
23 void testDiskQueries() {
24 Map<String, String> deviceMap = Iostat.queryPartitionToMountMap();
25 assertThat("Partition to mount map should not be empty", deviceMap, is(not(anEmptyMap())));
26
27 Map<String, Quintet<String, String, String, String, Long>> deviceStringMap = Iostat
28 .queryDeviceStrings(deviceMap.keySet());
29 assertThat("Device string map should not be empty", deviceStringMap, is(not(anEmptyMap())));
30 }
31 }