小编Mac*_*łas的帖子

使用Jackson作为Jersey客户端序列化器

在使用Jersey Client API时,是否可以使用Jackson作为JSON数据的序列化程序/编组程序而不是JAXB?

如果是这样如何配置呢?

jersey jackson

36
推荐指数
3
解决办法
3万
查看次数

Maven maven-exec-plugin多个执行配置

是否可以通过命令行中的id调用maven-exec-plugin(或任何其他插件)执行?

假设我的pom.xml文件如下所示:

<project>
[...]
    <plugin>
    <groupId>org.codehaus.mojo</groupId>
    <artifactId>exec-maven-plugin</artifactId>
    <executions>
        <execution>
            <id>foo</id>
            <goals>
                <goal>exec</goal>
            </goals>
            <phase></phase>
            <configuration>
                <executable>echo</executable>
                <arguments>
                    <argument>foo</argument>
                </arguments>
            </configuration>
        </execution>
        <execution>
            <id>bar</id>
            <goals>
                <goal>exec</goal>
            </goals>
            <phase></phase>
            <configuration>
                <executable>echo</executable>
                <arguments>
                    <argument>bar</argument>
                </arguments>
                </configuration>
            </execution>
        </executions>
    </plugin>
[...]
</project>
Run Code Online (Sandbox Code Playgroud)

现在可以打电话了

mvn exec:exec

有一些额外的魔法来运行执行"foo"?

好奇的是,有一个替代解决方案,使用此处提供的配置文件:http: //www.mail-archive.com/user@mojo.codehaus.org/msg00151.html

maven-2 maven

29
推荐指数
3
解决办法
2万
查看次数

Eclipse JUnit4:使用名称模式排除测试

是否可以在Eclipse的JUnit Run配置中指定一个名称模式(比如**/integration/*Test),在运行项目的所有测试时应该从测试运行中排除?

查看运行/调试配置中的选项我认为这个问题可以简化为:是否可以根据junit runner命令行参数排除某些测试.

我对创建(和维护)测试套件不感兴趣.

另一种替代解决方案(尽管对此仍然不感兴趣)是创建包含测试文件的单独目录:

  • yourProject /测试
  • yourProject /集成的测试

并选择该目录以运行其中的所有测试(或更改"运行配置"的"测试"选项卡中的"在所选项目,包或源文件夹中运行所有测试").

我正在使用:

  • Eclipse 3.5
  • JUnit 4

任何提示/建议非常感谢!

eclipse junit

7
推荐指数
1
解决办法
2692
查看次数

标签 统计

eclipse ×1

jackson ×1

jersey ×1

junit ×1

maven ×1

maven-2 ×1