20

I've got a nive bridge that allows me to run JBehave tests through JUnit with deeper integration than out of the box from JBehave - my JUnit hierarchy now shows each story file and the scenarios under it so you can see which scenarios have failed. This is all working well, except that you can't double-click on a failed sceanrio in Eclipse and get it to jump to the relevant line in the story file.

The JUnit Description class is designed around tests being Java methods, but I was wondering if there was some cunning way of indicating the location to make this work (e.g. in the annotations list).

Thanks.

t0rx
  • 363
  • 2
  • 8

1 Answers1

1

I think most Java IDEs actually react to the message or stack trace given when a JUnit test fails. For example in IntelliJ, failure lines are highlighted and clickable so long as they have SomeFileTheIDEKnows.java:123.

Can you get a stack trace or failure message to show that when a JUnit test fails?

Freiheit
  • 8,408
  • 6
  • 59
  • 101