Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-13 Thread Joseph Wilk
It looks like a nice shortcut for those times when you are registering simple one-off listeners. While it does provide a nice shortcut I can see reasons why that shortcut might be bad(in some cases). Separating registering and implementation can be a good thing. *Split the logic. *Organise

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-13 Thread aslak hellesoy
On Wed, Aug 13, 2008 at 2:25 AM, Zach Dennis [EMAIL PROTECTED] wrote: Sometimes I don't have a full need to make a class to do something, yet I want something readable and concise. This is influenced from the joys of JavaScript. Today I made this happen. Love it, like it, hate it, WDYT? As

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-13 Thread Zach Dennis
On Wed, Aug 13, 2008 at 5:26 AM, Joseph Wilk [EMAIL PROTECTED] wrote: It looks like a nice shortcut for those times when you are registering simple one-off listeners. While it does provide a nice shortcut I can see reasons why that shortcut might be bad(in some cases). Separating

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-13 Thread Zach Dennis
On Wed, Aug 13, 2008 at 8:29 AM, aslak hellesoy [EMAIL PROTECTED] wrote: On Wed, Aug 13, 2008 at 2:25 AM, Zach Dennis [EMAIL PROTECTED] wrote: Sometimes I don't have a full need to make a class to do something, yet I want something readable and concise. This is influenced from the joys of

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-13 Thread aslak hellesoy
On Wed, Aug 13, 2008 at 5:18 PM, Zach Dennis [EMAIL PROTECTED] wrote: On Wed, Aug 13, 2008 at 11:00 AM, aslak hellesoy [EMAIL PROTECTED] wrote: On Wed, Aug 13, 2008 at 4:50 PM, Zach Dennis [EMAIL PROTECTED] wrote: On Wed, Aug 13, 2008 at 8:29 AM, aslak hellesoy [EMAIL PROTECTED] wrote: On

[rspec-users] WDYT, simple, anonymous story listeners?

2008-08-12 Thread Zach Dennis
Sometimes I don't have a full need to make a class to do something, yet I want something readable and concise. This is influenced from the joys of JavaScript. Today I made this happen. Love it, like it, hate it, WDYT? Spec::Story::Runner.register_listener FunctionalStruct.new( :run_started =

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-12 Thread Tero Tilus
2008-08-12 20:25, Zach Dennis: Sometimes I don't have a full need to make a class to do something, How's that _essentially_ different from making a class or extending an existing class? I am not knowledgeable enough to just see it, and becaus I can't understand the motivation, I'm bound to hate

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-12 Thread Zach Dennis
On Wed, Aug 13, 2008 at 12:24 AM, Tero Tilus [EMAIL PROTECTED] wrote: 2008-08-12 20:25, Zach Dennis: Sometimes I don't have a full need to make a class to do something, How's that _essentially_ different from making a class or extending an existing class? I am not knowledgeable enough to

Re: [rspec-users] WDYT, simple, anonymous story listeners?

2008-08-12 Thread Mark Wilden
On Tue, Aug 12, 2008 at 9:54 PM, Zach Dennis [EMAIL PROTECTED] wrote: There is nothing wrong with this, but there are times when it feels dirty and unnecessary to create yet another class with some methods The proposed solution looks very nice, but I've never been convinced by the yet