[rspec-devel] [ rspec-Feature Requests-8507 ] change #include to some other name

noreply at rubyforge.org noreply at rubyforge.org
Thu Feb 8 08:20:03 EST 2007


Feature Requests item #8507, was opened at 2007-02-08 13:20
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3152&aid=8507&group_id=797

Category: runner module
Group: None
Status: Open
Priority: 3
Submitted By: David Chelimsky (dchelimsky)
Assigned to: Nobody (None)
Summary: change #include to some other name

Initial Comment:
RSpec supports inclusion of a module in a context:

context "some context" do
  include SomeModule
end

The initial intent of this was to enable state sharing across contexts and/or introduce helper methods that might be used across contexts.

Unfortunately, the use of the name "include" has led to some perception problems. It does NOT work exactly like Ruby's include does, but the name leads to the expectation that it should.

I'd like to propose that we deprecate the name "include" and replace it with some other name like "include_methods_from" or something like that (suggestions please!!!), which indicates that methods from the module will be made available, but it should not otherwise be expected to behave as Module#include behaves.

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3152&aid=8507&group_id=797


More information about the rspec-devel mailing list