Skip to content

Commit

Permalink
change test names and add openshift test
Browse files Browse the repository at this point in the history
  • Loading branch information
jcarranzan committed Sep 17, 2024
1 parent 873783e commit 402254e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
5 changes: 5 additions & 0 deletions quarkus-picocli/src/test/java/OpenShiftPicocliIT.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import io.quarkus.test.scenarios.OpenShiftScenario;

@OpenShiftScenario
public class OpenShiftPicocliIT extends PicocliIT {
}
14 changes: 7 additions & 7 deletions quarkus-picocli/src/test/java/PicocliIT.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class PicocliIT {
.setAutoStart(false);

@Test
public void testAgeCommandWithApplicationScoped() {
public void verifyErrorForApplicationScopedBeanInPicocliCommand() {
String expectedAgeOutput = String.format("Your age is: %s", AGE_VALUE);
try {
runAsync(ageApp::start);
Expand All @@ -62,7 +62,7 @@ public void testAgeCommandWithApplicationScoped() {
}

@Test
public void testGreetingCommand() {
public void verifyGreetingCommandOutputsExpectedMessage() {
String expectedOutput = String.format("Hello %s!", GREETING_NAME_VALUE);
try {
runAsync(greetingApp::start);
Expand All @@ -74,7 +74,7 @@ public void testGreetingCommand() {
}

@Test
void blankArgsGreetingCommand() {
void verifyErrorForBlankArgumentsInGreetingCommand() {
String expectedError = "Unmatched arguments from index 0: '', '--name', 'QE'";
try {
runAsync(greetingBlankArgumentApp::start);
Expand All @@ -85,7 +85,7 @@ void blankArgsGreetingCommand() {
}

@Test
void invalidArgsGreetingCommand() {
void verifyErrorForInvalidArgumentsInGreetingCommand() {
String expectedError = "Unknown options: '-x', 'QE'";
try {
runAsync(greetingInvalidArgumentApp::start);
Expand All @@ -99,7 +99,7 @@ void invalidArgsGreetingCommand() {
* Chain Commands in a Single Execution is not possible
*/
@Test
public void testBothCommandsAtTheSameTime() {
public void verifyErrorForMultipleCommandsWithoutTopCommand() {
bothTopCommandApp
.withProperty("quarkus.args",
GREETING_COMMAND_DESC + " " + GREETING_NAME_OPTION + " " + "EEUU" + " " +
Expand All @@ -115,8 +115,8 @@ public void testBothCommandsAtTheSameTime() {
}

@Test
public void testCustomizedCommandLine() {
String expectedOutput = "CustomizedName";
public void verifyCustomizedCommandLineBehavior() {
String expectedOutput = "customized";
try {
runAsync(customizedCommandApp::start);
customizedCommandApp.logs().assertContains(expectedOutput);
Expand Down

0 comments on commit 402254e

Please sign in to comment.