-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b868706
commit 60fef5e
Showing
4 changed files
with
45 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
module MySpec | ||
module IntegrationHelper | ||
def self.included(base) | ||
base.class_eval do | ||
include DSLHelper | ||
end | ||
end | ||
end | ||
|
||
module DSLHelper | ||
def self.included(base) | ||
class << base | ||
alias_method :Given, :describe | ||
alias_method :And, :describe | ||
alias_method :When, :describe | ||
end | ||
|
||
RSpec::Core::ExampleGroup.class_eval do | ||
define_example_method :Then | ||
define_example_method :And_ | ||
define_example_method :Or | ||
end | ||
end | ||
end | ||
end | ||
|
||
class Object | ||
alias_method :Scenario, :describe | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters