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

Before and After hooks support added to Rhino #587

Merged
merged 3 commits into from
Sep 12, 2013
Merged

Before and After hooks support added to Rhino #587

merged 3 commits into from
Sep 12, 2013

Conversation

ruifigueira
Copy link
Contributor

Hi,

I just added Before and After hooks support to the rhino backend.
Rhino scripts can now call two new functions, Before and After, whitch receive:

  • a function
  • a optional string or array of strings with tag expressions for that hook
  • a optional object with timeout and/or order properties

Example:

Before(function() {
  // do something
}, [ "@mytag" ], { timeout : 100, order : 1 });

After(function() {
  // do something
}, [ "@mytag" ]);

@aslakhellesoy
Copy link
Contributor

Awesome! Can you fix the typo that caused Travis to fail the build?

@ruifigueira
Copy link
Contributor Author

Oops, sorry about that. I just fixed that. Also, I replaced tab indentation with space indentation

@aslakhellesoy
Copy link
Contributor

Thanks!

My impression (from mailing list and issue tracker activity) is that not many people are using Cucumber-Rhino. It's very cool to see that there is at least one person using it! :-)

I'd love to know more...

@aslakhellesoy aslakhellesoy merged commit 3841f93 into cucumber:master Sep 12, 2013
@ruifigueira
Copy link
Contributor Author

Well, I just start using cucumber-jvm two days ago. Cucumber-rhino caught my atention because I'm using Rhino as a scripting language in another project of mine, and I was surprised to see that it was soooo easy to extend it! Cucumber-JVM is a great piece of software :)
I needed those Before and After hooks so that I could start and stop a Selenium WebDriver, and it is working like a charm now.
Hopefully, you'll see more contributions from me to cucumber-rhino, because I see great value there!

Thanks!

@jorgeazevedo
Copy link

@ruifigueira using a Selenium WebDriver with cucumber-rhino is exactly what I'd like to do! Since I'm just getting started this is proving really complicated. Is it possible you share your code? Maybe we could setup a hello world type project for rhino/selenium

Sorry to hijack this pull request discussion, by the way, but I can't find a way to contact you!

@lock
Copy link

lock bot commented Oct 25, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Oct 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants