From 4d6f2789cc75d1e733b5bedaedcc0b2774f1aaab Mon Sep 17 00:00:00 2001 From: Marco Bungart Date: Sun, 7 May 2023 00:33:02 +0200 Subject: [PATCH] Cleanup codestarter tests - Remove unnecessary modifiers - Unify line-breaks - Unify indentation --- .../java/org/acme/lambda/LambdaHandlerTest.java | 5 ++--- .../native-test/java/org/acme/funqy/FunqyIT.java | 2 +- .../src/test/java/org/acme/funqy/FunqyTest.java | 5 ++--- .../GreetingFunctionsCloudEventsTest.java | 2 +- .../GreetingFunctionsPubSubTest.java | 2 +- .../GreetingFunctionsStorageTest.java | 2 +- .../java/org/acme/funqy/cloudevent/FunqyIT.java | 2 +- .../org/acme/funqy/cloudevent/FunqyTest.java | 5 ++--- .../HelloWorldBackgroundFunctionTest.java | 2 +- .../HelloWorldCloudEventsFunctionTest.java | 2 +- .../HelloWorldHttpFunctionTest.java | 2 +- .../src/test/java/org/acme/FunctionTest.java | 4 ++-- .../src/test/java/org/acme/GreetingTest.java | 5 ++--- .../src/test/java/org/acme/MyFunctionsTest.java | 7 +++---- .../test/java/org/acme/HelloGrpcServiceTest.java | 5 ++--- .../acme/{resource.class-name}IT.tpl.qute.java | 2 +- .../acme/{resource.class-name}Test.tpl.qute.java | 5 ++--- .../acme/{resource.class-name}IT.tpl.qute.java | 2 +- .../acme/{resource.class-name}Test.tpl.qute.java | 5 ++--- .../acme/{resource.class-name}IT.tpl.qute.java | 2 +- .../acme/{resource.class-name}Test.tpl.qute.java | 5 ++--- ..._ilove_quark_us_lambda_LambdaHandlerTest.java | 5 ++--- ...c_test_java_ilove_quark_us_funqy_FunqyIT.java | 2 +- ...test_java_ilove_quark_us_funqy_FunqyTest.java | 5 ++--- ...nctions_GreetingFunctionsCloudEventsTest.java | 2 +- ...oudfunctions_GreetingFunctionsPubSubTest.java | 2 +- ...udfunctions_GreetingFunctionsStorageTest.java | 2 +- ...test_java_ilove_quark_us_MyFunctionsTest.java | 7 +++---- ..._ilove_quark_us_funqy_cloudevent_FunqyIT.java | 2 +- ...love_quark_us_funqy_cloudevent_FunqyTest.java | 5 ++--- ...nctions_HelloWorldBackgroundFunctionTest.java | 2 +- ...ctions_HelloWorldCloudEventsFunctionTest.java | 2 +- ...loudfunctions_HelloWorldHttpFunctionTest.java | 2 +- ...java_ilove_quark_us_HelloGrpcServiceTest.java | 4 ++-- ...a_ilove_quark_us_MyDeclarativeRoutesTest.java | 16 ++++++++-------- 35 files changed, 59 insertions(+), 72 deletions(-) diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/amazon-lambda-example/java/src/test/java/org/acme/lambda/LambdaHandlerTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/amazon-lambda-example/java/src/test/java/org/acme/lambda/LambdaHandlerTest.java index 95252e2a2e9b26..ec935b9b5975f1 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/amazon-lambda-example/java/src/test/java/org/acme/lambda/LambdaHandlerTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/amazon-lambda-example/java/src/test/java/org/acme/lambda/LambdaHandlerTest.java @@ -8,10 +8,9 @@ import static org.hamcrest.CoreMatchers.containsString; @QuarkusTest -public class LambdaHandlerTest { - +class LambdaHandlerTest { @Test - public void testSimpleLambdaSuccess() throws Exception { + void testSimpleLambdaSuccess() throws Exception { // you test your lambdas by invoking on http://localhost:8081 // this works in dev mode too diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/native-test/java/org/acme/funqy/FunqyIT.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/native-test/java/org/acme/funqy/FunqyIT.java index 54da79f8c643b3..dc381eb9d88b28 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/native-test/java/org/acme/funqy/FunqyIT.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/native-test/java/org/acme/funqy/FunqyIT.java @@ -3,7 +3,7 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class FunqyIT extends FunqyTest { +class FunqyIT extends FunqyTest { // Run the same tests diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/test/java/org/acme/funqy/FunqyTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/test/java/org/acme/funqy/FunqyTest.java index 24d660e94898a2..878e31c2a6704d 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/test/java/org/acme/funqy/FunqyTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-amazon-lambda-example/java/src/test/java/org/acme/funqy/FunqyTest.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.containsString; @QuarkusTest -public class FunqyTest { - +class FunqyTest { @Test - public void testFunqyLambda() throws Exception { + void testFunqyLambda() throws Exception { // you test your lambdas by invoking on http://localhost:8081 // this works in dev mode too diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsCloudEventsTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsCloudEventsTest.java index ca4f54b69ae9a4..881889a1a0952b 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsCloudEventsTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsCloudEventsTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_CLOUD_EVENTS, functionName = "helloCloudEvent") class GreetingFunctionsCloudEventsTest { @Test - public void testHelloCloudEvent() { + void testHelloCloudEvent() { given() .body("{\n" + " \"bucket\": \"MY_BUCKET\",\n" + diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsPubSubTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsPubSubTest.java index d01e8941c7cd3c..02bd0fc89ccc58 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsPubSubTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsPubSubTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_BACKGROUND, functionName = "helloPubSubWorld") class GreetingFunctionsPubSubTest { @Test - public void testHelloPubSubWorld() { + void testHelloPubSubWorld() { given() .body("{\"data\":{\"data\":\"world\"}}") .when() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsStorageTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsStorageTest.java index 7f12f32d344c7a..8ef9bfc1068969 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsStorageTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-google-cloud-functions-example/java/src/test/java/org/acme/funqygooglecloudfunctions/GreetingFunctionsStorageTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_BACKGROUND, functionName = "helloGCSWorld") class GreetingFunctionsStorageTest { @Test - public void testHelloGCSWorld() { + void testHelloGCSWorld() { given() .body("{\"data\":{\"name\":\"hello.txt\"}}") .when() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/native-test/java/org/acme/funqy/cloudevent/FunqyIT.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/native-test/java/org/acme/funqy/cloudevent/FunqyIT.java index 963be67ece024a..49cf0ae5dfad3f 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/native-test/java/org/acme/funqy/cloudevent/FunqyIT.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/native-test/java/org/acme/funqy/cloudevent/FunqyIT.java @@ -3,7 +3,7 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class FunqyIT extends FunqyTest { +class FunqyIT extends FunqyTest { // Run the same tests diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/test/java/org/acme/funqy/cloudevent/FunqyTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/test/java/org/acme/funqy/cloudevent/FunqyTest.java index 38b42eacc82362..0340c6450543aa 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/test/java/org/acme/funqy/cloudevent/FunqyTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/funqy-knative-events-example/java/src/test/java/org/acme/funqy/cloudevent/FunqyTest.java @@ -12,10 +12,9 @@ import static org.hamcrest.Matchers.notNullValue; @QuarkusTest -public class FunqyTest { - +class FunqyTest { @Test - public void testCloudEvent() { + void testCloudEvent() { RestAssured.given().contentType("application/json") .header("ce-specversion", "1.0") .header("ce-id", UUID.randomUUID().toString()) diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldBackgroundFunctionTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldBackgroundFunctionTest.java index b23ec79b213312..db6ed1f55963fd 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldBackgroundFunctionTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldBackgroundFunctionTest.java @@ -11,7 +11,7 @@ @WithFunction(FunctionType.BACKGROUND) class HelloWorldBackgroundFunctionTest { @Test - public void testAccept() { + void testAccept() { given() .body("{\"data\":{\"name\":\"hello.txt\"}}") .when() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldCloudEventsFunctionTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldCloudEventsFunctionTest.java index 69239e60e71068..4dcd0bdfb12248 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldCloudEventsFunctionTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldCloudEventsFunctionTest.java @@ -11,7 +11,7 @@ @WithFunction(FunctionType.CLOUD_EVENTS) class HelloWorldCloudEventsFunctionTest { @Test - public void testAccept() { + void testAccept() { given() .body("{\n" + " \"bucket\": \"MY_BUCKET\",\n" + diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldHttpFunctionTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldHttpFunctionTest.java index bbbec9751c95b3..0307a6da30ceb2 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldHttpFunctionTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/examples/google-cloud-functions-example/java/src/test/java/org/acme/googlecloudfunctions/HelloWorldHttpFunctionTest.java @@ -12,7 +12,7 @@ @WithFunction(FunctionType.HTTP) class HelloWorldHttpFunctionTest { @Test - public void testService() { + void testService() { when() .get() .then() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-codestart/java/src/test/java/org/acme/FunctionTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-codestart/java/src/test/java/org/acme/FunctionTest.java index b699e5643d4ebe..9481e8461430f8 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-codestart/java/src/test/java/org/acme/FunctionTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-codestart/java/src/test/java/org/acme/FunctionTest.java @@ -27,7 +27,7 @@ * Unit test for Function class. */ @QuarkusTest -public class FunctionTest { +class FunctionTest { @Inject Function function; @@ -36,7 +36,7 @@ public class FunctionTest { * Unit test for HttpTriggerJava method. */ @Test - public void testHttpTriggerJava() throws Exception { + void testHttpTriggerJava() throws Exception { // Setup @SuppressWarnings("unchecked") final HttpRequestMessage> req = mock(HttpRequestMessage.class); diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-http-codestart/java/src/test/java/org/acme/GreetingTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-http-codestart/java/src/test/java/org/acme/GreetingTest.java index 2b549c62a38f0d..a78bbfdbeeb8af 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-http-codestart/java/src/test/java/org/acme/GreetingTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/azure-functions-http-codestart/java/src/test/java/org/acme/GreetingTest.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.is; @QuarkusTest -public class GreetingTest { - +class GreetingTest { @Test - public void testHelloEndpoint() { + void testHelloEndpoint() { given() .when().get("/hello") .then() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/funqy-http-codestart/java/src/test/java/org/acme/MyFunctionsTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/funqy-http-codestart/java/src/test/java/org/acme/MyFunctionsTest.java index d192d90bf55db2..862782c740b535 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/funqy-http-codestart/java/src/test/java/org/acme/MyFunctionsTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/funqy-http-codestart/java/src/test/java/org/acme/MyFunctionsTest.java @@ -8,10 +8,9 @@ import static org.hamcrest.Matchers.containsString; @QuarkusTest -public class MyFunctionsTest { - +class MyFunctionsTest { @Test - public void testFun() { + void testFun() { given() .post("/fun") .then() @@ -20,7 +19,7 @@ public void testFun() { } @Test - public void testFunWithName() { + void testFunWithName() { given() .contentType(ContentType.JSON) .body("{\"name\": \"Friend\"}") diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/grpc-codestart/java/src/test/java/org/acme/HelloGrpcServiceTest.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/grpc-codestart/java/src/test/java/org/acme/HelloGrpcServiceTest.java index 2d8502471625eb..16e9bc1ee25ad2 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/grpc-codestart/java/src/test/java/org/acme/HelloGrpcServiceTest.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/grpc-codestart/java/src/test/java/org/acme/HelloGrpcServiceTest.java @@ -10,13 +10,12 @@ import org.junit.jupiter.api.Test; @QuarkusTest -public class HelloGrpcServiceTest { - +class HelloGrpcServiceTest { @GrpcClient HelloGrpc helloGrpc; @Test - public void testHello() { + void testHello() { HelloReply reply = helloGrpc .sayHello(HelloRequest.newBuilder().setName("Neo").build()).await().atMost(Duration.ofSeconds(5)); assertEquals("Hello Neo!", reply.getMessage()); diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java index 41cdadc1779529..e1dc4213b0e541 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java @@ -3,6 +3,6 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class {resource.class-name}IT extends {resource.class-name}Test { +class {resource.class-name}IT extends {resource.class-name}Test { // Execute the same tests but in packaged mode. } diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java index aca41d9528af05..b02cd1aac42e27 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.is; @QuarkusTest -public class {resource.class-name}Test { - +class {resource.class-name}Test { @Test - public void testHelloEndpoint() { + void testHelloEndpoint() { given() .when().get("{resource.path}") .then() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java index 41cdadc1779529..e1dc4213b0e541 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java @@ -3,6 +3,6 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class {resource.class-name}IT extends {resource.class-name}Test { +class {resource.class-name}IT extends {resource.class-name}Test { // Execute the same tests but in packaged mode. } diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java index aca41d9528af05..b02cd1aac42e27 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/resteasy-reactive-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.is; @QuarkusTest -public class {resource.class-name}Test { - +class {resource.class-name}Test { @Test - public void testHelloEndpoint() { + void testHelloEndpoint() { given() .when().get("{resource.path}") .then() diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java index 41cdadc1779529..e1dc4213b0e541 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/native-test/java/org/acme/{resource.class-name}IT.tpl.qute.java @@ -3,6 +3,6 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class {resource.class-name}IT extends {resource.class-name}Test { +class {resource.class-name}IT extends {resource.class-name}Test { // Execute the same tests but in packaged mode. } diff --git a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java index aca41d9528af05..b02cd1aac42e27 100644 --- a/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java +++ b/devtools/project-core-extension-codestarts/src/main/resources/codestarts/quarkus/extension-codestarts/spring-web-codestart/java/src/test/java/org/acme/{resource.class-name}Test.tpl.qute.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.is; @QuarkusTest -public class {resource.class-name}Test { - +class {resource.class-name}Test { @Test - public void testHelloEndpoint() { + void testHelloEndpoint() { given() .when().get("{resource.path}") .then() diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/AmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_lambda_LambdaHandlerTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/AmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_lambda_LambdaHandlerTest.java index a4cd06203b932f..e91c7204a9709b 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/AmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_lambda_LambdaHandlerTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/AmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_lambda_LambdaHandlerTest.java @@ -8,10 +8,9 @@ import static org.hamcrest.CoreMatchers.containsString; @QuarkusTest -public class LambdaHandlerTest { - +class LambdaHandlerTest { @Test - public void testSimpleLambdaSuccess() throws Exception { + void testSimpleLambdaSuccess() throws Exception { // you test your lambdas by invoking on http://localhost:8081 // this works in dev mode too diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyIT.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyIT.java index 832ce6b1bb785f..96079c2b9bed6e 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyIT.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyIT.java @@ -3,7 +3,7 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class FunqyIT extends FunqyTest { +class FunqyIT extends FunqyTest { // Run the same tests diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyTest.java index b0f17923ae8ce2..d268c28f4e1d49 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyAmazonLambdaCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_FunqyTest.java @@ -7,10 +7,9 @@ import static org.hamcrest.CoreMatchers.containsString; @QuarkusTest -public class FunqyTest { - +class FunqyTest { @Test - public void testFunqyLambda() throws Exception { + void testFunqyLambda() throws Exception { // you test your lambdas by invoking on http://localhost:8081 // this works in dev mode too diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsCloudEventsTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsCloudEventsTest.java index b902cb6bc535d0..3d30c3af9214b8 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsCloudEventsTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsCloudEventsTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_CLOUD_EVENTS, functionName = "helloCloudEvent") class GreetingFunctionsCloudEventsTest { @Test - public void testHelloCloudEvent() { + void testHelloCloudEvent() { given() .body("{\n" + " \"bucket\": \"MY_BUCKET\",\n" + diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsPubSubTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsPubSubTest.java index 96f75c3ec6777f..2af025ae5f3fbb 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsPubSubTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsPubSubTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_BACKGROUND, functionName = "helloPubSubWorld") class GreetingFunctionsPubSubTest { @Test - public void testHelloPubSubWorld() { + void testHelloPubSubWorld() { given() .body("{\"data\":{\"data\":\"world\"}}") .when() diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsStorageTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsStorageTest.java index be65eb45f9dc51..c4395dde4c52be 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsStorageTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyGoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_funqygooglecloudfunctions_GreetingFunctionsStorageTest.java @@ -11,7 +11,7 @@ @WithFunction(value = FunctionType.FUNQY_BACKGROUND, functionName = "helloGCSWorld") class GreetingFunctionsStorageTest { @Test - public void testHelloGCSWorld() { + void testHelloGCSWorld() { given() .body("{\"data\":{\"name\":\"hello.txt\"}}") .when() diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyHttpCodestartTest/testContent/src_test_java_ilove_quark_us_MyFunctionsTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyHttpCodestartTest/testContent/src_test_java_ilove_quark_us_MyFunctionsTest.java index 65850cad613eba..2db4081158f244 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyHttpCodestartTest/testContent/src_test_java_ilove_quark_us_MyFunctionsTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyHttpCodestartTest/testContent/src_test_java_ilove_quark_us_MyFunctionsTest.java @@ -8,10 +8,9 @@ import static org.hamcrest.Matchers.containsString; @QuarkusTest -public class MyFunctionsTest { - +class MyFunctionsTest { @Test - public void testFun() { + void testFun() { given() .post("/fun") .then() @@ -20,7 +19,7 @@ public void testFun() { } @Test - public void testFunWithName() { + void testFunWithName() { given() .contentType(ContentType.JSON) .body("{\"name\": \"Friend\"}") diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyIT.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyIT.java index a7d713e8d54f40..4c9e912a408b00 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyIT.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyIT.java @@ -3,7 +3,7 @@ import io.quarkus.test.junit.QuarkusIntegrationTest; @QuarkusIntegrationTest -public class FunqyIT extends FunqyTest { +class FunqyIT extends FunqyTest { // Run the same tests diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyTest.java index 9eb6515ddcc7f9..c6902421e0903d 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/FunqyKnativeEventsCodestartTest/testContent/src_test_java_ilove_quark_us_funqy_cloudevent_FunqyTest.java @@ -12,10 +12,9 @@ import static org.hamcrest.Matchers.notNullValue; @QuarkusTest -public class FunqyTest { - +class FunqyTest { @Test - public void testCloudEvent() { + void testCloudEvent() { RestAssured.given().contentType("application/json") .header("ce-specversion", "1.0") .header("ce-id", UUID.randomUUID().toString()) diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldBackgroundFunctionTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldBackgroundFunctionTest.java index d1226399ee1d43..a55e8a38e2bf79 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldBackgroundFunctionTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldBackgroundFunctionTest.java @@ -11,7 +11,7 @@ @WithFunction(FunctionType.BACKGROUND) class HelloWorldBackgroundFunctionTest { @Test - public void testAccept() { + void testAccept() { given() .body("{\"data\":{\"name\":\"hello.txt\"}}") .when() diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldCloudEventsFunctionTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldCloudEventsFunctionTest.java index c407b7258d43fa..8c32e661a14f90 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldCloudEventsFunctionTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldCloudEventsFunctionTest.java @@ -11,7 +11,7 @@ @WithFunction(FunctionType.CLOUD_EVENTS) class HelloWorldCloudEventsFunctionTest { @Test - public void testAccept() { + void testAccept() { given() .body("{\n" + " \"bucket\": \"MY_BUCKET\",\n" + diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldHttpFunctionTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldHttpFunctionTest.java index bdc8438f56a975..2ce1ad20a14a48 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldHttpFunctionTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/GoogleCloudFunctionsCodestartTest/testContent/src_test_java_ilove_quark_us_googlecloudfunctions_HelloWorldHttpFunctionTest.java @@ -12,7 +12,7 @@ @WithFunction(FunctionType.HTTP) class HelloWorldHttpFunctionTest { @Test - public void testService() { + void testService() { when() .get() .then() diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/GrpcCodestartTest/testContent/src_test_java_ilove_quark_us_HelloGrpcServiceTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/GrpcCodestartTest/testContent/src_test_java_ilove_quark_us_HelloGrpcServiceTest.java index 0d49375e4cafdf..4f06eb5fc2cf82 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/GrpcCodestartTest/testContent/src_test_java_ilove_quark_us_HelloGrpcServiceTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/GrpcCodestartTest/testContent/src_test_java_ilove_quark_us_HelloGrpcServiceTest.java @@ -10,13 +10,13 @@ import org.junit.jupiter.api.Test; @QuarkusTest -public class HelloGrpcServiceTest { +class HelloGrpcServiceTest { @GrpcClient HelloGrpc helloGrpc; @Test - public void testHello() { + void testHello() { HelloReply reply = helloGrpc .sayHello(HelloRequest.newBuilder().setName("Neo").build()).await().atMost(Duration.ofSeconds(5)); assertEquals("Hello Neo!", reply.getMessage()); diff --git a/integration-tests/devtools/src/test/resources/__snapshots__/ReactiveRoutesCodestartTest/testContent/src_test_java_ilove_quark_us_MyDeclarativeRoutesTest.java b/integration-tests/devtools/src/test/resources/__snapshots__/ReactiveRoutesCodestartTest/testContent/src_test_java_ilove_quark_us_MyDeclarativeRoutesTest.java index 7e340f95e9b833..835389f490e3a8 100644 --- a/integration-tests/devtools/src/test/resources/__snapshots__/ReactiveRoutesCodestartTest/testContent/src_test_java_ilove_quark_us_MyDeclarativeRoutesTest.java +++ b/integration-tests/devtools/src/test/resources/__snapshots__/ReactiveRoutesCodestartTest/testContent/src_test_java_ilove_quark_us_MyDeclarativeRoutesTest.java @@ -9,14 +9,14 @@ @QuarkusTest public class MyDeclarativeRoutesTest { - @Test - public void testHelloRouteEndpointWithNameParameter() { - given().when().get("hello-route?name=Quarkus").then().statusCode(200).body(is("Hello Quarkus !!")); - } + @Test + public void testHelloRouteEndpointWithNameParameter() { + given().when().get("hello-route?name=Quarkus").then().statusCode(200).body(is("Hello Quarkus !!")); + } - @Test - public void testHelloRouteEndpointWithoutNameParameter() { - given().when().get("hello-route").then().statusCode(200).body(is("Hello Reactive Route !!")); - } + @Test + public void testHelloRouteEndpointWithoutNameParameter() { + given().when().get("hello-route").then().statusCode(200).body(is("Hello Reactive Route !!")); + } }