kaocha-cucumber icon indicating copy to clipboard operation
kaocha-cucumber copied to clipboard

Trying to get json output

Open p14n opened this issue 6 years ago • 3 comments

Hi,

I thought I'd be able to get json output with cucumber jvm by using system props:

clojure -J-Dcucumber.options="-p json:target/x.json" -Sdeps '{:deps {lambdaisland/kaocha {:mvn/version "0.0-418"} lambdaisland/kaocha-cucumber {:mvn/version "0.0-46"}}}' -m kaocha.runner "$@"

While the JSONFormatter is correctly instantiated and the json file created, nothing appears in the file, and I cant see any of the event handlers being hit in debug. Can anyone explain this or suggest an alternative route?

Cheers

p14n avatar May 08 '19 22:05 p14n

Oh I see now the registerHandlerFor on the event handler isn't implemented :(

p14n avatar May 09 '19 08:05 p14n

Hi Dean, making Cucumber work with Kaocha has been mostly a process of trial and error, as it's a use case that the Cucumber API isn't designed for (Kaocha is the driver in this case, whereas Cucumber expects to be the driver), and because I had limited time/funding to get this to a usable state, so there are likely still several loose ends.

I can't immediately say if what you are asking for is feasible or easy, but I could look into it. Are you using Kaocha in a commercial setting? I'm happy to do a feasibility study and estimation for a fixed price, and then you can decide if you want to commission this feature or not.

Alternatively I'm happy to provide feedback or set up a pairing session if you want to implement this yourself.

Thanks!

plexus avatar May 09 '19 09:05 plexus

Hey @plexus - thanks for the response. I was just trying to get non-techy readable output but have managed to get something useful with a reporting function and the markdown printing in this repo.

Cheers, Dean

p14n avatar May 09 '19 21:05 p14n