Skip to content

Commit cf863d6

Browse files
JUnit Jupiter best practices (#81)
Co-authored-by: Moderne <[email protected]>
1 parent ff8627e commit cf863d6

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

plexus-interactivity-api/src/test/java/org/codehaus/plexus/components/interactivity/DefaultPrompterComponentTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131

3232
import static org.junit.jupiter.api.Assertions.assertNotNull;
3333

34-
public class DefaultPrompterComponentTest extends InjectedTest {
34+
class DefaultPrompterComponentTest extends InjectedTest {
3535

3636
@Inject
3737
private Prompter prompter;

plexus-interactivity-api/src/test/java/org/codehaus/plexus/components/interactivity/DefaultPrompterTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,25 +32,25 @@
3232
import static java.util.Objects.requireNonNull;
3333
import static org.junit.jupiter.api.Assertions.assertEquals;
3434

35-
public class DefaultPrompterTest {
35+
class DefaultPrompterTest {
3636
@Test
37-
void promptSimple() throws PrompterException {
37+
void promptSimple() throws Exception {
3838
final InMemoryOutput out = new InMemoryOutput();
3939
final Prompter prompter = new DefaultPrompter(out, new InMemoryInput("ok"));
4040
prompter.prompt("test");
4141
assertEquals("test: ", out.builder.toString());
4242
}
4343

4444
@Test
45-
void promptOption() throws PrompterException {
45+
void promptOption() throws Exception {
4646
final InMemoryOutput out = new InMemoryOutput();
4747
final Prompter prompter = new DefaultPrompter(out, new InMemoryInput("ok"));
4848
prompter.prompt("test", "value");
4949
assertEquals("test value: ", out.builder.toString());
5050
}
5151

5252
@Test
53-
void promptOptions() throws PrompterException {
53+
void promptOptions() throws Exception {
5454
final InMemoryOutput out = new InMemoryOutput();
5555
final Prompter prompter = new DefaultPrompter(out, new InMemoryInput("yes"));
5656
prompter.prompt("test", asList("yes", "no"), "value");

0 commit comments

Comments
 (0)