Module: Spec::Example::ExampleGroupMethods

Module | Spec::Example::ExampleGroupMethods
In: | lib/spec/example/example_group_methods.rb

### Methods

build_description_from context describe described_class described_type description description_args example example_group_hierarchy include_constants_in it it_should_behave_like nested_descriptions pending_implementation run set_description specify xexample xit xspecify

### Included Modules

Spec::Example::BeforeAndAfterHooks Spec::Example::Subject::ExampleGroupMethods Spec::Example::PredicateMatchers Spec::Example::ArgsAndOptions

### Attributes

location | [R] |
matcher_class | [RW] |

### Public Class methods

build_description_from(*args)

### Public Instance methods

context(*args, &example_group_block)

Alias for describe

describe(*args, &example_group_block)

Makes the describe/it syntax available from a class. For example:

      class StackSpec < Spec::ExampleGroup
        describe Stack, "with no elements"

        before
          @stack = Stack.new
        end

        it "should raise on pop" do
          lambda{ @stack.pop }.should raise_error
        end
      end

described_class()
described_type()
description()
description_args()
example(description=nil, options={}, backtrace=nil, &implementation)

Creates an instance of the current example group class and adds it to a collection of examples of the current example group.

example_group_hierarchy()
include_constants_in(mod)
it(description=nil, options={}, backtrace=nil, &implementation)

Alias for example

it_should_behave_like(*shared_example_groups)

Use this to pull in examples from shared example groups.

nested_descriptions()
pending_implementation()
run(run_options)
set_description(*args)
specify(description=nil, options={}, backtrace=nil, &implementation)

Alias for example

xexample(description=nil, opts={}, &block)

Use this to temporarily disable an example.

xit(description=nil, opts={}, &block)

Alias for xexample

xspecify(description=nil, opts={}, &block)

Alias for xexample

[Validate]