Forum: RSpec [Proposal] deprecate context() at the top level

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
5d38ab152e1e3e219512a9859fcd93af?d=identicon&s=25 David Chelimsky (Guest)
on 2009-03-13 14:42
(Received via mailing list)
Hi all,

There are two tickets in lighthouse that point to problems with the
use of context() in RSpec:

* conflict with JRuby:

* request context() be deprecated

As there are a lot of people (and libraries) that mix and match
describe() and context(), I don't plan to simply remove it. However, a
couple of suggestions have come up that I'm considering. Here's the

== deprecate and eventually remove context() ONLY AT THE TOP LEVEL

In my personal use, and from what I've seen in other libraries that
are driven with RSpec, this is the common use of context():

  describe "Something" do
    context "in some context" do

You would *still be able to do that*, but you would *not be able to do

  context "Something" do
    context "in some context" do


I'd like to know if you think removing context a the top level will
create conflicts with your code or libraries you use. Please comment
in instead of
here - I'd like to keep the conversation in one place, if possible.

Thanks for playing,
This topic is locked and can not be replied to.