class

Mocks::Scope

Inherits Reference < Object

Provides isolation between logical areas. Each area has its own registry.

Constructors

current

Retrieves the active scope.

Source
push

Starts a new scope. #pop should be called after the scope is no longer needed.

Source

Class methods

pop

Ends a previous scope. This should be called for each #push without a block.

Source
push

Starts a new scope for the duration of the block. Yields the new scope to the block and returns the value from the block. #pop is called automatically as part of this method.

Source

Instance methods

registry

Registry for the scope.

Source