Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gherkin / Cucumber Test System #663

Closed
senips opened this issue Mar 2, 2015 · 12 comments
Closed

Gherkin / Cucumber Test System #663

senips opened this issue Mar 2, 2015 · 12 comments

Comments

@senips
Copy link

senips commented Mar 2, 2015

I would like to know is there any plan for Gherkin based test system. I feel that Fitnesse is kind of side lined with Cucumber. Fitnesse is powerful and I know Cucumber table is originated from Fit, so shouldn't we be up to that?

Also another question: do you guys have any plans for providing Fitnesse runner work within Development IDE run or seamlessly work between IDE and Browser based run?.

@amolenaar
Copy link
Collaborator

Have a look at https://github.com/amolenaar/fitnesse-jbehave-test-system. It's using JBehave, the original BDD tool for Java. Still have to make a release.

IDE support would be nice, but it's a big effort to pull it off. I'd love to have it. The FitNesse code base should be in a good enough shape to be used by an IDE plugin.

@senips
Copy link
Author

senips commented Mar 4, 2015

Thanks for sharing it, sure, I will take a look at it.
Actually long time ago I started a project for IDE integration but went into a different direction and it was for Visual Studio .NET http://cmdfit.codeplex.com/

@six42
Copy link
Contributor

six42 commented Mar 10, 2015

Hi Senthil,
could you elaborate more what kind of IDE integration you are looking for?
Maybe describing the user story in Cucumber style :) .

In Eclipse you can use the build in browser to work with FitNesse pages and can control the edit / test / view cycle fully with keyboard shortcuts and without the mouse. To test suites you can define an ant task and call this from within Eclipse like a Junit task.
In other words you can do already a lot within a single program.

@senips
Copy link
Author

senips commented Mar 12, 2015

I use Fitnesse for about 10+ years and used it in many different ways including what you suggested.

  1. I face hard time in debugging or during red green refactor approach seamlessly in a BDD sense. For example, when writing business rule tests, i see a disconnected way of writing in Fitnesse. You write fixtures in IDE and run it with Fitnesse via browser so here is the disconnect for seamless development. Those days it was cool but not anymore after many tools have emerged.

  2. Current Fitnesse Junit support is kind of a wrapper call right now and someone needs to download the FitNesse source code to understand it as how to use it and it does not provide any detail except pass/fail if you run it. So long way to go on that.

Currently I suggest for my people to go for UI based acceptance but not for business rule tests with Fitnesse because of this. And that is the reason why I always wanted for something developer friendly within in IDE and without having to have an additional server part.

Lastly to answer your question about what kind of IDE integration I want is something like Cucumber-Jvm but in Fitnesse way

@woodybrood
Copy link
Collaborator

Gherkin itself is the syntax/parser mechanism for cucumber. It doesn't use
the render to html then parse the tables approach that FitNesse does, but
it also doesn't support much of what makes the FitNesse pages work as a
wiki. I think asking for Gherkin sort of confused what I think you really
want, which is a more direct way to invoke FitNesse pages in an IDE.

It seems to me that you don't really think Gherkin is the need, but the
Cucumber-like ability to run the tests w/o spinning up the web server. What
ever we would do would require something that parsed the wiki pages and
turns them into HTML. That's pretty essential, as Slim and Fit get the
rendered HTML, which they then parse to execute tests. Using the web server
means that we don't have too many ways to do that. If you want Gherkin
support too, I think that is a separate issue from a web-serverless
execution mode.

If we do implement something, it still needs to support the various
languages and variations: Java, .Net, FitLibrary, etc.

That said, it isn't a bad idea. Personally when I was doing a lot of
FitNesse work, I did as much as possible in Vim or Sublime Text, as I
really wanted the features of the editor to make editing easier. Barring
we go to a more powerful editor option like Atom, I don't think the editing
experience for more code-minded folks will ever compare to an IDE. The
catch though to that is the IDE support or users working in the IDE really
have to know and understand the folder structure rules for FitNesse to do
it right. Since Eclipse/Sublime/VisualStudio don't know or enforce those
behaviors natively.

On Wed, Mar 11, 2015 at 8:40 PM, Senthil Maruthaiappan <
notifications@github.com> wrote:

I use Fitnesse for about 10+ years and used it in many different ways
including what you suggested.

  1. I face hard time in debugging or during red green refactor approach
    seamlessly in a BDD sense. For example, when writing business rule tests, i
    see a disconnected way of writing in Fitnesse. You write fixtures in IDE
    and run it with Fitnesse via browser so here is the disconnect for seamless
    development.

  2. Current Fitnesse Junit support is kind of a wrapper call and someone
    needs to download the code understand it as how to use it and it does not
    provide any detail except pass/fail if you run it. So long way to go on
    that.

Currently I suggest for my people to go for UI based acceptance but not
for business rule. That is the reason why I always wanted for something
developer friendly within in IDE and without having to have an additional
server part.


Reply to this email directly or view it on GitHub
#663 (comment).

@senips
Copy link
Author

senips commented Mar 13, 2015

I agree that my original question is kind two different questions. ok, Fitnesse works by test system like Fit, Slim so similarly one can think of Gherkin as a type of Test System too which provides FitNesse users a choice and subside that Cucumber fever people. Secondly, using standalone editors like notepad, vi are good but trust me, most of the developers all the time with IDEs some way and also you think of version control support too with FitNesse. Right now one need to manually check in those context.txt and property.xml files. It really sucks with that SVN, there is no way to ignore unwanted files. On TFS you must check out those files before editing in Fitnesse. So if you go with IDE then you get it free or provision to extend it like test runners, version control, editors and possibly syntax highlighting on wiki tables.

Well you mentioning about folder structure, yes it is a challenge for IDEs. Personally I think that we should get out of that concept some way especially with that twin files (txt, xml) and folder name acting as a suite name / test name. I do not know anyone hit the problem of long directory names and could not delete in windows because of too lengthy! However this was not the topic but happened to record here.

@amolenaar
Copy link
Collaborator

I agree with you that the roundtrip for developers is quite long (edit wiki text, update fixture code, compile and run from a web browser). It's hard for a developer who's used to running all tools and tests from his IDE. I checked out a few plugins for IntelliJ (since that's what I'm using), but none of them got past the level of syntax highlighting. :(

Something that FitNesse could play a part in (related to Gherkin), is that it can provide an organised overview of the scenario's. Kinda like https://cucumber.pro does it. Because apart from the test execution FitNesse can also make such information available through a browser and it can manage the test history. At least, that was one of the benefits I saw when writing the JBehave plugin for FitNesse.

@senips
Copy link
Author

senips commented Mar 13, 2015

Cucumber is just another flavour of JUnit stuff and sugar coated with Gherkin. To me, it is meant more for developers. Seriously I do not know how many organization Business Owners sit and write specifications in Gherkin. Back to the topic, yes in FitNesse one can understand what is failing and what is passing at the end but not that Junit style assert crap mudding the water and to say, assert wherever you think of given/when/then. As you said, I agree that FitNesse provides you an organized view and even more powerful test inheritance. Actually the wow feature of FitNesse is scenario table to me which Cucumber sucks really and I wouldn't spend time&money writing in Gherkin for that, just forget it. If the people do not know the right tools for the job and how to use it wisely then its going to cost hell a lot money for a company. It's pity to hear about cucumber.pro and I just laugh at this. Also look at that SpecFlow guys with SpecFlow Plus, all traps.

Well, FitNesse is far more than enough to me except reduce the foot print and need to find a way for seamless red/green/refactor development jelled with IDE.

@amolenaar
Copy link
Collaborator

I've been building a plugin for IntelliJ lately: https://github.com/amolenaar/idea-fitnesse.

It has syntax highlighting and referencing between fixtures, tables and scenario tables so far.

Next up is execution.

@senips
Copy link
Author

senips commented Jun 16, 2015

Glad to see coming up on IntelliJ. If you break up into task, possibly I could sign up to contribute whenever I get time if you like. Possibly you could come up with a release plan and interested people can contribute to it.

@amolenaar
Copy link
Collaborator

I have a list of tasks/features on the wiki page of the project. Like I said, I'm currently working on getting the test case execution working.

If you can compile it (grade build) and give it a try, that would be much appreciated.

@senips
Copy link
Author

senips commented Jun 16, 2015

I was able to compile it with 2 warnings on DecisionTableSuite.scala:90 and /ScriptTableSuite.scala:107.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants