Skip to content

Commit

Permalink
Add Javadoc to command-mode testing API
Browse files Browse the repository at this point in the history
  • Loading branch information
geoand committed Jul 14, 2022
1 parent 0cc407b commit aa70206
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,11 @@
import java.lang.annotation.Target;

/**
* Annotation for {@link QuarkusMainTest} and {@link QuarkusMainIntegrationTest} used to
* Annotation for {@link QuarkusMainTest} and {@link QuarkusMainIntegrationTest} that is used to launch command line
* applications.
* The annotation is meant to be used on test methods only.
*
* See also {@link LaunchResult} and {@link QuarkusMainLauncher}
*/
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

import java.util.List;

/**
* Contains information about a run (via {@link Launch}) of a command line application.
* The class is meant to be used as a test method parameter giving the test the ability
* to assert various aspects of the run.
*/
public interface LaunchResult {

default String getOutput() {
Expand All @@ -22,4 +27,4 @@ default void echoSystemOut() {
List<String> getErrorStream();

int exitCode();
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
package io.quarkus.test.junit.main;

/**
* The annotation is meant to be used on test methods only and it allows the launching a command line application with
* arbitrary parameters.
*
* See also {@link LaunchResult} and {@link Launch}
*/
public interface QuarkusMainLauncher {

LaunchResult launch(String... args);
Expand Down

0 comments on commit aa70206

Please sign in to comment.