Skip to content

Commit

Permalink
testability: bench test commands should have automated coverage usin…
Browse files Browse the repository at this point in the history
…g simulator #5562

 only:trying to improve multi-threading
  • Loading branch information
rusefillc committed Sep 13, 2023
1 parent debea23 commit 69b07e1
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package com.rusefi;

import com.devexperts.logging.Logging;

import java.io.BufferedReader;
import java.io.File;
import java.io.IOException;
Expand All @@ -16,6 +18,8 @@
* Andrey Belomutskiy, (c) 2013-2020
*/
public class SimulatorExecHelper {
private final static Logging log = Logging.getLogging(SimulatorExecHelper.class);

private final static NamedThreadFactory THREAD_FACTORY = new NamedThreadFactory("SimulatorExecHelper", true);

private static final String SIMULATOR_BUILD_RUSEFI_SIMULATOR = "../simulator/build/rusefi_simulator";
Expand Down Expand Up @@ -114,7 +118,7 @@ public static void startSimulator() throws InterruptedException {
CountDownLatch simulatorStarted = new CountDownLatch(1);
new Thread(() -> runSimulator(simulatorStarted), "simulator process").start();
simulatorStarted.await(1, TimeUnit.MINUTES);
System.out.println("Let's give it some time to start...");
Thread.sleep(5);
log.info("Let's give it some time to start...");
Thread.sleep(35);
}
}

0 comments on commit 69b07e1

Please sign in to comment.