Re: [rspec-users] shared examples sharing methods

2009-06-18 Thread Andrew Premdas
2009/6/18 Ben Mabey > David Chelimsky wrote: > >> On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas >> wrote: >> >> >>> Please have a look at >>> http://gist.github.com/131277 >>> What I'd like to do is create a shared_examples group which I can >>> parametize >>> a method. So my shared example wo

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Ben Mabey
David Chelimsky wrote: On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas wrote: Please have a look at http://gist.github.com/131277 What I'd like to do is create a shared_examples group which I can parametize a method. So my shared example would perhaps use method named_address=, or set_named_

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Nicolás Sanguinetti
On Thu, Jun 18, 2009 at 1:36 AM, Stephen Eley wrote: > On Thu, Jun 18, 2009 at 12:17 AM, Ben Mabey wrote: >> >> If you do go down that route, I recommend method calls instead of instance >> variables.  That way it will yell out you when you forget to define one. :) > > Hey, instance variables do th

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Stephen Eley
On Thu, Jun 18, 2009 at 12:17 AM, Ben Mabey wrote: > > If you do go down that route, I recommend method calls instead of instance > variables.  That way it will yell out you when you forget to define one. :) Hey, instance variables do that too. Yelling == "my tests fail." >8-> (And if they don'

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Ben Mabey
David Chelimsky wrote: On Wed, Jun 17, 2009 at 1:19 PM, Matt Wynne wrote: On 17 Jun 2009, at 16:21, David Chelimsky wrote: On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas wrote: Please have a look at http://gist.github.com/131277 What I'd like to do is create a shared_examples

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Stephen Eley
On Wed, Jun 17, 2009 at 11:14 AM, Andrew Premdas wrote: > What I'd like to do is create a shared_examples group which I can parametize > a method. So my shared example would perhaps use method named_address=, or > set_named_address and then groups that behave like "Named address" would be > able to

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread David Chelimsky
On Wed, Jun 17, 2009 at 1:19 PM, Matt Wynne wrote: > > On 17 Jun 2009, at 16:21, David Chelimsky wrote: > >> On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas >> wrote: >>> >>> Please have a look at >>> http://gist.github.com/131277 >>> What I'd like to do is create a shared_examples group which I c

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread Matt Wynne
On 17 Jun 2009, at 16:21, David Chelimsky wrote: On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas wrote: Please have a look at http://gist.github.com/131277 What I'd like to do is create a shared_examples group which I can parametize a method. So my shared example would perhaps use method

Re: [rspec-users] shared examples sharing methods

2009-06-17 Thread David Chelimsky
On Wed, Jun 17, 2009 at 10:14 AM, Andrew Premdas wrote: > Please have a look at > http://gist.github.com/131277 > What I'd like to do is create a shared_examples group which I can parametize > a method. So my shared example would perhaps use method named_address=, or > set_named_address and then gr

[rspec-users] shared examples sharing methods

2009-06-17 Thread Andrew Premdas
Please have a look at http://gist.github.com/131277 What I'd like to do is create a shared_examples group which I can parametize a method. So my shared example would perhaps use method named_address=, or set_named_address and then groups that behave like "Named address" would be able to override