Repository: quarkusio/quarkus
Issue: ./gradlew quarkusTest does not include the test/resources on the classpath

### Describe the bug

When I load files from the `src/test/resources` in my unit tests run via `./gradlew quarkusTest` I get null back. If I run the same test using `./gradlew build` the resource is successfully loaded. The same happens when I run the test from the `quarkus dev` cli tool.

### Expected behavior

When running tests with `./gradlew quarkusTest` or `quarkus dev` my tests should be able to read files in the `src/test/resources`

### Actual behavior

If I read a file `src/test/resources/test.txt` from a test:

```
var test = this.getClass().getResource("test.txt");
```
The var `test` is null if I run the test via `./gradlew quarkusTest` or `quarkus dev` but if I run it via `./gradlew build` it is not.

### How to Reproduce?

https://github.com/martinffx/quarkus-bug

`./gradlew build` works
`./gradlew quarkusTest` fails

### Output of `uname -a` or `ver`

Darwin Martin-MacBook-Pro.local 20.6.0 Darwin Kernel Version 20.6.0: Wed Jun 23 00:26:31 PDT 2021; root:xnu-7195.141.2~5/RELEASE_X86_64 x86_64

### Output of `java -version`

_No response_

### GraalVM version (if different from Java)

penjdk version "11.0.9.1" 2020-11-04 LTS OpenJDK Runtime Environment Corretto-11.0.9.12.1 (build 11.0.9.1+12-LTS) OpenJDK 64-Bit Server VM Corretto-11.0.9.12.1 (build 11.0.9.1+12-LTS, mixed mode)

### Quarkus version or git rev

Client Version 2.2.1.Final

### Build tool (ie. output of `mvnw --version` or `gradlew --version`)

------------------------------------------------------------ Gradle 6.9 ------------------------------------------------------------  Build time:   2021-05-07 07:28:53 UTC Revision:     afe2e24ababc7b0213ccffff44970aa18035fc0e  Kotlin:       1.4.20 Groovy:       2.5.12 Ant:          Apache Ant(TM) version 1.10.9 compiled on September 27 2020 JVM:          11.0.9.1 (Amazon.com Inc. 11.0.9.1+12-LTS) OS:           Mac OS X 10.16 x86_64

### Additional information

_No response_

Changed files:
core/deployment/src/main/java/io/quarkus/deployment/dev/testing/TestSupport.java

diff --git a/core/deployment/src/main/java/io/quarkus/deployment/dev/testing/TestSupport.java b/core/deployment/src/main/java/io/quarkus/deployment/dev/testing/TestSupport.java
index 1e65b09d078..fd85de6413b 100644
--- a/core/deployment/src/main/java/io/quarkus/deployment/dev/testing/TestSupport.java
+++ b/core/deployment/src/main/java/io/quarkus/deployment/dev/testing/TestSupport.java
@@ -2,10 +2,11 @@
 
 import java.nio.file.Path;
 import java.nio.file.Paths;
-import java.util.ArrayList;
 import java.util.Collections;
+import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Optional;
+import java.util.Set;
 import java.util.concurrent.CopyOnWriteArrayList;
 import java.util.regex.Pattern;
 
@@ -121,8 +122,11 @@ public void init() {
         }
         if (testCuratedApplication == null) {
             try {
-                List<Path> paths = new ArrayList<>();
+                Set<Path> paths = new LinkedHashSet<>();
                 paths.add(Paths.get(context.getApplicationRoot().getTest().get().getClassesPath()));
+                if (context.getApplicationRoot().getTest().get().getResourcesOutputPath() != null) {
+                    paths.add(Paths.get(context.getApplicationRoot().getTest().get().getResourcesOutputPath()));
+                }
                 paths.addAll(curatedApplication.getQuarkusBootstrap().getApplicationRoot().toList());
                 testCuratedApplication = curatedApplication.getQuarkusBootstrap().clonedBuilder()
                         .setMode(QuarkusBootstrap.Mode.TEST)