Hello, I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see Dave Astel''s talk as well as several of my coworkers. The developers at my workplace are experienced Agile developers. What would be some good things to focus on for this brown bag? Are there slides to presentations that would be useful? Any resistance/skepticism, and how to best address these concerns? I''m kindof nervous because there is some skepticism toward rspec and BDD. Mainly: - Test::Unit already does that, so why do we need rspec? - It''s not production ready. (Stack traces are too cluttered for RspecOnRails; although this opinion was based on version 0.6) - New people will be confused seeing rspec code (although this is solved by more education, usage, encapsulation, etc.) - BDD is TDD using "should" instead of "assert" There are also a number of people who do see benefits to using rspec and are excited by it, so I do have "allies". :) I''m particularly interested in showing: - How BDD is really good TDD without sounding religious - How rspec encourages developers to create better "tests" than Test::Unit Thank you, Brian Takita -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061120/f45ad744/attachment-0001.html
Not sure if you saw my RejectConf lightning talk, but I have a (poor) video of it. :P -Steven On 20-Nov-06, at 6:07 PM, Brian Takita wrote:> Hello, > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for > my company (Pivotal Computer Systems, http://www.pivotalsf.com). I > did see Dave Astel''s talk as well as several of my coworkers. > The developers at my workplace are experienced Agile developers. > > What would be some good things to focus on for this brown bag? > Are there slides to presentations that would be useful? > Any resistance/skepticism, and how to best address these concerns? > > I''m kindof nervous because there is some skepticism toward rspec > and BDD. > > Mainly: > Test::Unit already does that, so why do we need rspec? > It''s not production ready. (Stack traces are too cluttered for > RspecOnRails; although this opinion was based on version 0.6) > New people will be confused seeing rspec code (although this is > solved by more education, usage, encapsulation, etc.) > BDD is TDD using "should" instead of "assert" > There are also a number of people who do see benefits to using > rspec and are excited by it, so I do have "allies". :) > > I''m particularly interested in showing: > How BDD is really good TDD without sounding religious > How rspec encourages developers to create better "tests" than > Test::Unit > Thank you, > Brian Takita > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061120/71d5b803/attachment.html
On 11/20/06, Steven Baker <srbaker at pobox.com> wrote:> > Not sure if you saw my RejectConf lightning talk, but I have a (poor) > video of it. :P >Yes I saw it. Do you have the video posted somewhere? -Steven> On 20-Nov-06, at 6:07 PM, Brian Takita wrote: > > Hello, > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my > company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see > Dave Astel''s talk as well as several of my coworkers. > The developers at my workplace are experienced Agile developers. > > What would be some good things to focus on for this brown bag? > Are there slides to presentations that would be useful? > Any resistance/skepticism, and how to best address these concerns? > > I''m kindof nervous because there is some skepticism toward rspec and BDD. > > Mainly: > > - Test::Unit already does that, so why do we need rspec? > - It''s not production ready. (Stack traces are too cluttered for > RspecOnRails; although this opinion was based on version 0.6) > - New people will be confused seeing rspec code (although this is > solved by more education, usage, encapsulation, etc.) > - BDD is TDD using "should" instead of "assert" > > There are also a number of people who do see benefits to using rspec and > are excited by it, so I do have "allies". :) > > I''m particularly interested in showing: > > - How BDD is really good TDD without sounding religious > - How rspec encourages developers to create better "tests" than > Test::Unit > > Thank you, > Brian Takita > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel > > > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel > >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061120/c2978e26/attachment.html
On 11/20/06, Brian Takita <brian.takita at gmail.com> wrote:> Hello, > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my > company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see Dave > Astel''s talk as well as several of my coworkers. > The developers at my workplace are experienced Agile developers. > > What would be some good things to focus on for this brown bag? > Are there slides to presentations that would be useful? > Any resistance/skepticism, and how to best address these concerns? > > I''m kindof nervous because there is some skepticism toward rspec and BDD. > > Mainly: > > Test::Unit already does that, so why do we need rspec?The whole context/specify thing makes you see "testing" in a different way. Sure, you can create multiple test cases to represent different contexts, but by naming them in text, they become easier to read and therefore easier to grok.> It''s not production ready. (Stack traces are too cluttered for RspecOnRails; > although this opinion was based on version 0.6)To some degree this seems true to me to me. While, with a few exceptions, the rspec core API is quite stable now, the rails plugin is quite volatile. For that reason, I think there is some risk to adopting the rails plugin right now. It really depends on your team and what the team values are. There is a lot to be gained from early adoption. You just have to have that mindset.> New people will be confused seeing rspec code (although this is solved by > more education, usage, encapsulation, etc.) > BDD is TDD using "should" instead of "assert"If all that you know of BDD is rspec, that''s an easy misunderstanding to have. I''d give Dan North''s blog a read to help understand the greater context. In the end it''s about language and collaboration between technical people and non-technical people. Also, even as a granular, developer practice (absent the wider team piece), rspec offers clarity in the way you organize your specs (by context). It offers clarity in the expression of expectations (actual.should == expected vs assert_equal(:am_i_expected_or_actual, :am_i_actual_or_expected).> There are also a number of people who do see benefits to using rspec and are > excited by it, so I do have "allies". :) > > I''m particularly interested in showing: > > How BDD is really good TDD without sounding religious > How rspec encourages developers to create better "tests" thanFocus on your own experience. Do you believe that BDD changes the conversation? Do you believe that you write better tests (if you MUST call them that) because rspec encourages you to do so? If so, then try to tap that. How are they better? Are you writing better code? Are your designs simpler? Are they easier to change later? Etc, etc. If the answer to these things is no, then you probably shouldn''t be evangelizing it. That would be dishonest. Just tell people about it and what your experience is either way (the things you like, the things you don''t). 2 cents.> Test::UnitThank you, > Brian Takita > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel > >
One of the things that has sold me on rspec--besides the fact that it encourages better tests--is the ability to print out the specs from your app. For example, the following are the start of some specs for an ecommerce app I am working on. I can take my tests (specs derived from user stories) and generate documentation that I can hand directly to the customer, and it makes perfect sense to them. There is no question as to what the app does and whether or not the specs are up to date. That alone is worth it''s weight in gold. A user - can purchase items - should have many orders A user purchasing items - should create an order - should add to the user''s orders - should create line items - should set line item amount to the item''s price - should set line item amount to 0 if item does not have a price An order - should have line_items - should have an invoice - should be invalid without an amount An invoice - should have many orders - should be invalid without an amount - should have many payments - should belong to a user Paying an invoice - should create a payment - should set payment amount equal to invoice amount - should set payment confirmation number Calling invoice.pay with an invalid credit card - should raise AuthorizationError A payment - should belong to an invoice - should be invalid without an amount Brandon On Nov 20, 2006, at 9:07 PM, Brian Takita wrote:> Hello, > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for > my company (Pivotal Computer Systems, http://www.pivotalsf.com). I > did see Dave Astel''s talk as well as several of my coworkers. > The developers at my workplace are experienced Agile developers. > > What would be some good things to focus on for this brown bag? > Are there slides to presentations that would be useful? > Any resistance/skepticism, and how to best address these concerns? > > I''m kindof nervous because there is some skepticism toward rspec > and BDD. > > Mainly: > Test::Unit already does that, so why do we need rspec? > It''s not production ready. (Stack traces are too cluttered for > RspecOnRails; although this opinion was based on version 0.6) > New people will be confused seeing rspec code (although this is > solved by more education, usage, encapsulation, etc.) > BDD is TDD using "should" instead of "assert" > There are also a number of people who do see benefits to using > rspec and are excited by it, so I do have "allies". :) > > I''m particularly interested in showing: > How BDD is really good TDD without sounding religious > How rspec encourages developers to create better "tests" than > Test::Unit > Thank you, > Brian Takita > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel
On 11/20/06, David Chelimsky <dchelimsky at gmail.com> wrote:> > On 11/20/06, Brian Takita <brian.takita at gmail.com> wrote: > > Hello, > > > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my > > company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see > Dave > > Astel''s talk as well as several of my coworkers. > > The developers at my workplace are experienced Agile developers. > > > > What would be some good things to focus on for this brown bag? > > Are there slides to presentations that would be useful? > > Any resistance/skepticism, and how to best address these concerns? > > > > I''m kindof nervous because there is some skepticism toward rspec and > BDD. > > > > Mainly: > > > > Test::Unit already does that, so why do we need rspec? > > The whole context/specify thing makes you see "testing" in a different > way. Sure, you can create multiple test cases to represent different > contexts, but by naming them in text, they become easier to read and > therefore easier to grok.I like that. It goes into the intent of the code. It seems even more important when pairs are switched frequently.> It''s not production ready. (Stack traces are too cluttered for > RspecOnRails; > > although this opinion was based on version 0.6) > > To some degree this seems true to me to me. While, with a few > exceptions, the rspec core API is quite stable now, the rails plugin > is quite volatile. For that reason, I think there is some risk to > adopting the rails plugin right now. It really depends on your team > and what the team values are. There is a lot to be gained from early > adoption. You just have to have that mindset.That makes sense. It seems like the best opportunity to use rspec on rails would be in starting a new project.> New people will be confused seeing rspec code (although this is solved by > > more education, usage, encapsulation, etc.) > > BDD is TDD using "should" instead of "assert" > > If all that you know of BDD is rspec, that''s an easy misunderstanding > to have. I''d give Dan North''s blog a read to help understand the > greater context. In the end it''s about language and collaboration > between technical people and non-technical people.Yes, I just started reading his blog. I like his perspective on communication with the client and his simple specification process in his Introducing BDD <http://dannorth.net/introducing-bdd> article. Also, even as a granular, developer practice (absent the wider team> piece), rspec offers clarity in the way you organize your specs (by > context). It offers clarity in the expression of expectations > (actual.should == expected vs assert_equal(:am_i_expected_or_actual, > :am_i_actual_or_expected). > > > There are also a number of people who do see benefits to using rspec and > are > > excited by it, so I do have "allies". :) > > > > I''m particularly interested in showing: > > > > How BDD is really good TDD without sounding religious > > How rspec encourages developers to create better "tests" than > > Focus on your own experience. Do you believe that BDD changes the > conversation? Do you believe that you write better tests (if you MUST > call them that)I like specs and behaviour myself. :) because rspec encourages you to do so? If so, then try> to tap that. How are they better? Are you writing better code? Are > your designs simpler? Are they easier to change later? Etc, etc. If > the answer to these things is no, then you probably shouldn''t be > evangelizing it. That would be dishonest. Just tell people about it > and what your experience is either way (the things you like, the > things you don''t). 2 cents.These are all good that set the appropriate tone for the brown bag. Theres alot to think about here. Thank you. Also, my coworker, Benny Sadeh advised me to treat the Brown Bag as a discussion and exploration of what can be learned from BDD and rspec. The group will probably be fairly sizable (mid to high teens) but that should be managable.> Test::UnitThank you, > > Brian Takita > > > > _______________________________________________ > > rspec-devel mailing list > > rspec-devel at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-devel > > > > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061120/2608cc2a/attachment.html
On 11/20/06, Brandon Keepers <bkeepers at gmail.com> wrote:> > One of the things that has sold me on rspec--besides the fact that it > encourages better tests--is the ability to print out the specs from > your app. For example, the following are the start of some specs for > an ecommerce app I am working on. I can take my tests (specs derived > from user stories) and generate documentation that I can hand > directly to the customer, and it makes perfect sense to them. There > is no question as to what the app does and whether or not the specs > are up to date. That alone is worth it''s weight in gold.Agreed. This is a sweet feature. A user> - can purchase items > - should have many orders > > A user purchasing items > - should create an order > - should add to the user''s orders > - should create line items > - should set line item amount to the item''s price > - should set line item amount to 0 if item does not have a price > > An order > - should have line_items > - should have an invoice > - should be invalid without an amount > > An invoice > - should have many orders > - should be invalid without an amount > - should have many payments > - should belong to a user > > Paying an invoice > - should create a payment > - should set payment amount equal to invoice amount > - should set payment confirmation number > > Calling invoice.pay with an invalid credit card > - should raise AuthorizationError > > A payment > - should belong to an invoice > - should be invalid without an amount > > Brandon > > On Nov 20, 2006, at 9:07 PM, Brian Takita wrote: > > > Hello, > > > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for > > my company (Pivotal Computer Systems, http://www.pivotalsf.com). I > > did see Dave Astel''s talk as well as several of my coworkers. > > The developers at my workplace are experienced Agile developers. > > > > What would be some good things to focus on for this brown bag? > > Are there slides to presentations that would be useful? > > Any resistance/skepticism, and how to best address these concerns? > > > > I''m kindof nervous because there is some skepticism toward rspec > > and BDD. > > > > Mainly: > > Test::Unit already does that, so why do we need rspec? > > It''s not production ready. (Stack traces are too cluttered for > > RspecOnRails; although this opinion was based on version 0.6) > > New people will be confused seeing rspec code (although this is > > solved by more education, usage, encapsulation, etc.) > > BDD is TDD using "should" instead of "assert" > > There are also a number of people who do see benefits to using > > rspec and are excited by it, so I do have "allies". :) > > > > I''m particularly interested in showing: > > How BDD is really good TDD without sounding religious > > How rspec encourages developers to create better "tests" than > > Test::Unit > > Thank you, > > Brian Takita > > _______________________________________________ > > rspec-devel mailing list > > rspec-devel at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-devel > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061120/52ec1174/attachment.html
On 11/21/06, Brian Takita <brian.takita at gmail.com> wrote:> Also, my coworker, Benny Sadeh advised me to treat the Brown Bag as a > discussion and exploration of what can be learned from BDD and rspec.Yes, yes, yes, yes! That is fantastic advice. Please report back to let us know how it all went. Good and/or bad. Good luck! David
On 11/21/06, Brian Takita <brian.takita at gmail.com> wrote:> Hello, > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my > company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see Dave > Astel''s talk as well as several of my coworkers. > The developers at my workplace are experienced Agile developers. > > What would be some good things to focus on for this brown bag? > Are there slides to presentations that would be useful? > Any resistance/skepticism, and how to best address these concerns? >I have had success with an explanation of the TDD journey as described here: http://www.behaviour-driven.org/TDDAdoptionProfile I usually present it with takahashi-style slides (http://tinyurl.com/o6psh) with the following words (one on each slide): * tests * confidence * before * documentation * discovery * behaviour * mocking> I''m kindof nervous because there is some skepticism toward rspec and BDD. > > Mainly: > > Test::Unit already does that, so why do we need rspec? > It''s not production ready. (Stack traces are too cluttered for RspecOnRails; > although this opinion was based on version 0.6) > New people will be confused seeing rspec code (although this is solved by > more education, usage, encapsulation, etc.) > BDD is TDD using "should" instead of "assert" > There are also a number of people who do see benefits to using rspec and are > excited by it, so I do have "allies". :) > > I''m particularly interested in showing: > > How BDD is really good TDD without sounding religious > How rspec encourages developers to create better "tests" than > Test::UnitThank you, > Brian Takita > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel > >
On 11/21/06, aslak hellesoy <aslak.hellesoy at gmail.com> wrote:> > On 11/21/06, Brian Takita <brian.takita at gmail.com> wrote: > > Hello, > > > > I''m scheduled to give a rspec brown bag this Wednesday (11/22) for my > > company (Pivotal Computer Systems, http://www.pivotalsf.com). I did see > Dave > > Astel''s talk as well as several of my coworkers. > > The developers at my workplace are experienced Agile developers. > > > > What would be some good things to focus on for this brown bag? > > Are there slides to presentations that would be useful? > > Any resistance/skepticism, and how to best address these concerns? > > > > I have had success with an explanation of the TDD journey as described > here: > http://www.behaviour-driven.org/TDDAdoptionProfile > > I usually present it with takahashi-style slides > (http://tinyurl.com/o6psh) with the following words (one on each > slide): > * tests > * confidence > * before > * documentation > * discovery > * behaviour > * mockingThis looks good. I think I''ll start with this and then move to the demo. Dan North''s ATM example is a juicy example for using rspec to drive domain concepts. The specdocs will come in handy here. Then I''ll do a short rspec on rails demo showing the model, control, view, and helper specs. Which should leave plenty of time for discussion and further examples. I''ll also invite discussion during the "presentation". Everyone, thanks for your help. Brian> I''m kindof nervous because there is some skepticism toward rspec and BDD. > > > > Mainly: > > > > Test::Unit already does that, so why do we need rspec? > > It''s not production ready. (Stack traces are too cluttered for > RspecOnRails; > > although this opinion was based on version 0.6) > > New people will be confused seeing rspec code (although this is solved > by > > more education, usage, encapsulation, etc.) > > BDD is TDD using "should" instead of "assert" > > There are also a number of people who do see benefits to using rspec and > are > > excited by it, so I do have "allies". :) > > > > I''m particularly interested in showing: > > > > How BDD is really good TDD without sounding religious > > How rspec encourages developers to create better "tests" than > > Test::UnitThank you, > > Brian Takita > > > > _______________________________________________ > > rspec-devel mailing list > > rspec-devel at rubyforge.org > > http://rubyforge.org/mailman/listinfo/rspec-devel > > > > > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061122/0bdc0d0b/attachment.html
On 11/21/06, David Chelimsky <dchelimsky at gmail.com> wrote:> > On 11/21/06, Brian Takita <brian.takita at gmail.com> wrote: > > Also, my coworker, Benny Sadeh advised me to treat the Brown Bag as a > > discussion and exploration of what can be learned from BDD and rspec. > > Yes, yes, yes, yes! That is fantastic advice. > > Please report back to let us know how it all went. Good and/or bad.Aiee. It got postponed to next Wednesday. Good luck!> David > _______________________________________________ > rspec-devel mailing list > rspec-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/rspec-users/attachments/20061122/089fad00/attachment-0001.html