lewismj / cucumber

Cucumber Test Framework & Plugin for SBT (BDD Testing in Scala)
Other
41 stars 18 forks source link

CucumberPlugin.cucumber is an InputKey. #29

Open Tillaert opened 7 years ago

Tillaert commented 7 years ago

sbt prevents sequencing of InputKeys.

CucumberPlugin.cucumber is defined as an InputKey, because it can pass additional commandline parameters.

Would it be an improvement to have a TaskKey that runs all cucumber tests, and a separate InputKey to run specific tests/pass other parameters?

For example how there is a test TaskKey[Unit] and testOnly InputKey[Unit]

lewismj commented 7 years ago

Thanks, I will take a look over the next few days. --Mike

lewismj commented 7 years ago

I will take a look at this, this evening.

lewismj commented 7 years ago

Still investigating, will setup a waffle board and bundle a few improvements into next release.

lewismj commented 7 years ago

Hi, I just did a re-write of the 'CucumberRunner'. If you run via the 'sbt test' then you don't need the plugin. The plugin is just used to provide a new command.

I can look into this issue, but I am wondering if the plugin is really necessary, i.e. how many people need a separate command 'sbt cucumber' vs just running via 'sbt test'.

My ex-firm use 'sbt cucumber', so I'll probably keep updating it. Will take a look shortly, delayed a bit with the runner re-write.

grahambarrgraham commented 7 years ago

We have a multi-module set-up, with a module containing our BDD tests in the main source tree, and some unit tests for that module in the test tree. So running sbt cucumber to run the BDD tests, and sbt test to run the unit tests (which test some aspects of the BDD code) works for us.

lewismj commented 7 years ago

Ok, I'll take another look at the plugin and tart it up a bit, may be a few days before I get chance (probably Monday).