Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/394.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/maven/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java maven冲浪插件排除一个包_Java_Maven_Unit Testing - Fatal编程技术网

Java maven冲浪插件排除一个包

Java maven冲浪插件排除一个包,java,maven,unit-testing,Java,Maven,Unit Testing,我尝试使用surfere插件从测试周期中排除一个包。 测试路径是:test/java/com/dir1/subdir1/ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>2.12

我尝试使用surfere插件从测试周期中排除一个包。 测试路径是:test/java/com/dir1/subdir1/

    <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <version>2.12.4</version>
            <configuration>
                <excludes>
                    <exclude>**/<subdir1>/*.java</exclude>
                </excludes>
            </configuration>
        </plugin>

org.apache.maven.plugins
maven surefire插件
2.12.4
**//*.爪哇

但我看到的总是日志,其中包含所有执行的测试。我的错误是什么?

为什么要排除测试?至少应该升级surefire插件-这是一个非常旧的版本。您是否尝试过
***/subdir1/*.java
而不是
***/*.java