JAVA-27357 Improve core-java-os build time

This commit is contained in:
anuragkumawat 2023-12-02 13:17:07 +05:30
parent dfb560b277
commit c8973d8cf3
2 changed files with 3 additions and 3 deletions

View File

@ -23,7 +23,7 @@ public class AppUnitTest {
soundRecorder.build(af);
try {
soundRecorder.start();
Thread.sleep(20000);
Thread.sleep(5000);
soundRecorder.stop();
} catch (InterruptedException ex) {
fail("Exception: " + ex);

View File

@ -69,7 +69,7 @@ public class ProcessApiUnitTest {
});
});
Thread.sleep(10000);
Thread.sleep(5000);
childProc = ProcessHandle.current().children();
childProc.forEach(procHandle -> {
@ -100,7 +100,7 @@ public class ProcessApiUnitTest {
private void waistCPU() throws NoSuchAlgorithmException {
ArrayList<Integer> randArr = new ArrayList<Integer>(4096);
SecureRandom sr = SecureRandom.getInstanceStrong();
Duration somecpu = Duration.ofMillis(4200L);
Duration somecpu = Duration.ofMillis(2000L);
Instant end = Instant.now().plus(somecpu);
while (Instant.now().isBefore(end)) {
// System.out.println(sr.nextInt());