author | Jaroslav Tulach <jtulach@netbeans.org> |
Sat, 14 Jun 2008 09:54:32 +0200 | |
changeset 107 | 907f5d8e343c |
child 263 | 7e8e995065c5 |
permissions | -rw-r--r-- |
jtulach@107 | 1 |
package org.apidesign.deadlock.startuplock; |
jtulach@107 | 2 |
|
jtulach@107 | 3 |
import java.io.File; |
jtulach@107 | 4 |
import java.util.logging.Handler; |
jtulach@107 | 5 |
import java.util.logging.Level; |
jtulach@107 | 6 |
import java.util.logging.LogRecord; |
jtulach@107 | 7 |
import java.util.logging.Logger; |
jtulach@107 | 8 |
import org.junit.After; |
jtulach@107 | 9 |
import org.junit.AfterClass; |
jtulach@107 | 10 |
import org.junit.Before; |
jtulach@107 | 11 |
import org.junit.BeforeClass; |
jtulach@107 | 12 |
import org.junit.Test; |
jtulach@107 | 13 |
import org.netbeans.junit.NbTestCase; |
jtulach@107 | 14 |
import static org.junit.Assert.*; |
jtulach@107 | 15 |
|
jtulach@107 | 16 |
// BEGIN: test.capture.logs.nbjunit |
jtulach@107 | 17 |
public class CLIHandlerBlockingWithNbTestCaseTest extends NbTestCase { |
jtulach@107 | 18 |
|
jtulach@107 | 19 |
public CLIHandlerBlockingWithNbTestCaseTest(String s) { |
jtulach@107 | 20 |
super(s); |
jtulach@107 | 21 |
} |
jtulach@107 | 22 |
|
jtulach@107 | 23 |
@Override |
jtulach@107 | 24 |
protected Level logLevel() { |
jtulach@107 | 25 |
return Level.ALL; |
jtulach@107 | 26 |
} |
jtulach@107 | 27 |
|
jtulach@107 | 28 |
|
jtulach@107 | 29 |
public void testStart() throws Exception { |
jtulach@107 | 30 |
File lockFile = File.createTempFile("pref", ".tmp"); |
jtulach@107 | 31 |
int result = CLIHandlerBlocking.start(lockFile); |
jtulach@107 | 32 |
assertEquals("Show a failure", -10, result); |
jtulach@107 | 33 |
} |
jtulach@107 | 34 |
} |
jtulach@107 | 35 |
// END: test.capture.logs.nbjunit |