nes1983
nes1983

Reputation: 15756

How to mark expected failures in SUnit?

How can I mark a unit test in SUnit (or phexample) as expected failures?

Upvotes: 5

Views: 157

Answers (1)

nes1983
nes1983

Reputation: 15756

Overwrite expectedFailures in your test. There's an example in WeakSetTest:

expectedFailures
    "such tests work in Squeak"
    ^ #(testDoAfter testIncludes )

Update:

As of Pharo 1.2, you can also add a pragma to the test method:

testDontWork
    <expectedFailure>
    self assert: 3 equals: 4

Upvotes: 4

Related Questions