小编Ale*_*rtz的帖子

将单元测试标记为JUnit4中的预期故障

是否有JUnit4的扩展,允许将某些测试标记为"预计会失败"?

我想用一些标记标记正在开发的当前功能的测试,例如@wip.对于这些测试,我想确保它们失败.

我的验收标准:

Scenario: A successful test tagged @wip is recorded as failure
    Given a successful test marked @wip
    When the test is executed
    Then the test is recorded as failure.

Scenario: A failing test tagged @wip is recorded as fine
    Given a failing test tagged @wip
    When the test is executed
    Then the test is recorded as fine.

Scenario: A successful test not tagged @wip is recorded as fine
    Given a successful test not tagged @wip
    When the test …
Run Code Online (Sandbox Code Playgroud)

junit unit-testing junit4

4
推荐指数
1
解决办法
4942
查看次数

标签 统计

junit ×1

junit4 ×1

unit-testing ×1