[Rspec-devel] innovations

Keith Hodges Keith.Hodges at warwick.ac.uk
Mon May 15 21:45:44 EDT 2006

Dear rspec(ted) folk,

I have added a couple of experimental features to spec.js and I wondered 
what you thought (given that Dave's previous feedback had such a radical 
impact last time around)

1. in a context setUp function any calls to other contexts invoke their 
setUp function too. This allows a context to call other contexts.


context("A stack with one item").setUp= function() 
		context("A new stack")
		stack.push( "one item" )


2. allow a context to include markPointWhere( ) items. e.g.

define context like so:

context( "typical stack use" ).setUp= function()
    stack= new Stack()
    markPointWhere( 'stack instanciated' )
    stack.push( 'one item' )
    markPointWhere( one item is pushed onto empty stack )

use like so:

context( "typical stack use", "stack instanciated" )

or even perhaps:

context( "typical stack use to point where stack instanciated" )


any thoughts?

Send instant messages to your online friends http://uk.messenger.yahoo.com 

More information about the Rspec-devel mailing list