From e4a9545cea69a05eb63b904918caad6ba91cbb97 Mon Sep 17 00:00:00 2001 From: Roman Shevchenko Date: Wed, 10 Feb 2016 11:02:16 +0100 Subject: [PATCH] Cleanup (a constant extracted) --- .../testSrc/com/intellij/util/io/BaseOutputReaderTest.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/platform/util/testSrc/com/intellij/util/io/BaseOutputReaderTest.java b/platform/util/testSrc/com/intellij/util/io/BaseOutputReaderTest.java index 07e6ade45fc9..f4847936e342 100644 --- a/platform/util/testSrc/com/intellij/util/io/BaseOutputReaderTest.java +++ b/platform/util/testSrc/com/intellij/util/io/BaseOutputReaderTest.java @@ -35,7 +35,8 @@ import static org.junit.Assert.assertNotNull; public class BaseOutputReaderTest { private static final String[] TEST_DATA = {"first\n", "incomplete", "-continuation\n", "last\n"}; - private static final int TIMEOUT = 500; + private static final int SEND_TIMEOUT = 500; + private static final int SLEEP_TIMEOUT = 60000; private static class TestOutputReader extends BaseOutputReader { private final List myLines = Collections.synchronizedList(new ArrayList()); @@ -119,12 +120,12 @@ public class BaseOutputReaderTest { @SuppressWarnings("BusyWait") public static void main(String[] args) throws InterruptedException { if (args.length > 0 && "sleep".equals(args[0])) { - Thread.sleep(60000); + Thread.sleep(SLEEP_TIMEOUT); } else if (args.length > 0 && "data".equals(args[0])) { for (String line : TEST_DATA) { System.out.print(line); - Thread.sleep(TIMEOUT); + Thread.sleep(SEND_TIMEOUT); } } else {