What's the difference between .feature and .specb, and which should I use? #11
|
I see both Is there any difference in how SpecBinder treats them, and is there a reason to pick one over the other? |
Replies: 1 comment
|
Either one works. Nothing about how SpecBinder reads your spec or generates your tests changes
That shows up most clearly in IntelliJ. SpecBinder has a companion IntelliJ plugin (optional — Telling SpecBinder which files to readYou point SpecBinder at your spec files with a
To change which extensions SpecBinder recognises, add a second annotation beside the first and @Gherkin2JUnit
@Gherkin2JUnitOptions(supportedFileExtensions = {"feature", "specb"}) // already the default
public abstract class ShoppingCartFeature { }In IntelliJThe SpecBinder plugin has its own separate setting for which files it gives editor support to: |
Either one works. Nothing about how SpecBinder reads your spec or generates your tests changes
between them, and you can switch later by renaming the file.
.specbis SpecBinder's own extension, and the one used throughout these docs and examples.Nothing else claims it, so a
.specbfile is unambiguously a SpecBinder spec — which is whatkeeps it out of the way of other tools.
That shows up most clearly in IntelliJ. SpecBinder has a companion IntelliJ plugin (optional —
your tests are generated with or without it) that adds editor support for spec files: clicking
through from a step to the code behind it, run buttons in the left margin, pass/fail marks after
a run. The Cucumber/Gherkin plu…