|
Scala example source code file (TerminalFactoryTest.java)
The Scala TerminalFactoryTest.java source codepackage scala.tools.jline; import org.junit.Before; import org.junit.Test; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; /** * Tests for the {@link TerminalFactory}. */ public class TerminalFactoryTest { @Before public void setUp() throws Exception { TerminalFactory.reset(); } @Test public void testConfigureNone() { TerminalFactory.configure(TerminalFactory.NONE); Terminal t = TerminalFactory.get(); assertNotNull(t); assertEquals(UnsupportedTerminal.class.getName(), t.getClass().getName()); } @Test public void testConfigureUnsupportedTerminal() { TerminalFactory.configure(UnsupportedTerminal.class.getName()); Terminal t = TerminalFactory.get(); assertNotNull(t); assertEquals(UnsupportedTerminal.class.getName(), t.getClass().getName()); } } Other Scala examples (source code examples)Here is a short list of links related to this Scala TerminalFactoryTest.java source code file: |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.