[rspec-users] Problem with Custom matcher and Blocks

2009-04-01 Thread Brandon Olivares
Hi, I'm trying to write my first custom matcher. Here's a bit of my example group. describe "/contact/index" do include FormMatchers before(:each) do render 'contact/index' end it "should show the contact form" do response.should have_a_contact_form end describe "the

Re: [rspec-users] [cucumber] How to add a after failure hook?

2009-04-01 Thread aslak hellesoy
2009/4/2 Tim Harper > Is currently a way to add a upon failure hook? I'd like to make it so > that, in the event of a failed assertion, Webrat will take the last > requested page and open it in a browser. > http://wiki.github.com/aslakhellesoy/cucumber/hooks After do |scenario| # currently n

[rspec-users] [cucumber] How to add a after failure hook?

2009-04-01 Thread Tim Harper
Is currently a way to add a upon failure hook? I'd like to make it so that, in the event of a failed assertion, Webrat will take the last requested page and open it in a browser. Thanks :) Tim ___ rspec-users mailing list rspec-users@rubyforge.org http:

Re: [rspec-users] Autospec stops running after tests are complete

2009-04-01 Thread rosentraterds
SOLVED: OK the problem was coming from Carlos Brando autotest-notification 1.9.0. It had to do with invalid checking of constants. Testing SUCCESS_SOUND.empty? instead of const_defined?("SUCCESS_SOUND"). I've fixed it in my fork. http://github.com/marcusrosentrater/autotest-notification/tree/mas

[rspec-users] RSpec-Rails 1.2.2 and Controllers without views - what to do?

2009-04-01 Thread Bira
I'm trying to upgrade to RSpec 1.2.2 in a Rails app, and reading Upgrade.rdoc I see that now every controller action must have a corresponding template for their specs to pass. However, we have a few controllers which only return XML or JSON as generated by Rails' to_xml and to_json methods, and so

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread James Byrne
Zach Dennis wrote: > > > Thanks for sharing James. I know when you first joined the list there > were a few frustrating moments, and it's really good to hear about > where you've come and how you've gotten there. This is helpful to both > newbs and seasoned BDDers alike, > I am very, very gratef

Re: [rspec-users] Autospec stops running after tests are complete

2009-04-01 Thread rosentraterds
Maybe related. When I try to run RSpactor (since autospec isn't working) it only runs 1 example. Still no solution. rosentraterds wrote: > > I'm thinking now the problem may be ZenTest 4.0. I reverted back to 3.11 > and it was working there. But 3.11 has conflicts with Rails 2.3.2 and I > need

Re: [rspec-users] Autospec stops running after tests are complete

2009-04-01 Thread rosentraterds
I'm thinking now the problem may be ZenTest 4.0. I reverted back to 3.11 and it was working there. But 3.11 has conflicts with Rails 2.3.2 and I need to run rails. Still need help if anybody has some for me. Thanks again. rosentraterds wrote: > > I installed an app template into an existing ra

[rspec-users] Autospec stops running after tests are complete

2009-04-01 Thread rosentraterds
I installed an app template into an existing rails install. In the process I upgraded to RSpec 1.2.2 and I'm running Rails 2.3.2. Now autospec will run once and then exit. Returning me to the CLI prompt. Any ideas? Thanks! -- View this message in context: http://www.nabble.com/Autospec-stops-

Re: [rspec-users] RSpec makes me want to write better code

2009-04-01 Thread aidy lewis
Hi David 2009/4/1 David Chelimsky : >. That said, in some idealistic BDD fashion, I'd think the best > deal would be the tester and developer pairing on automating AC. Then > that developer would pair with another developer driving out the code > w/ TDD. If we have two different sets of people i

[rspec-users] ticket 44

2009-04-01 Thread aidy lewis
Hi, Ticket 44 is resolved, I am using 0.2.3 and attempting to throw the html upon a failure Before do |scenario| @sc = scenario end After do puts @sc.methods.sort throw $browser.html @sc.failed? end Have these getters not been released or is my implementation flawed? Thanks Aidy ___

Re: [rspec-users] rspec-users Digest, Vol 34, Issue 2

2009-04-01 Thread Charleno Pires
e a lot of code out there at this basic a level. > > Any ideas? > > Scott > > On Wed, Apr 1, 2009 at 6:57 AM, Stephen Eley wrote: > >> 2009/4/1 Pablo L. de Miranda : >> > @Fernando - So what material you recommend to start a study in rSpec? >> >> 1.) The W

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Zach Dennis
On Wed, Apr 1, 2009 at 11:50 AM, James Byrne wrote: > Pablo L. de Miranda wrote: >> @Fernando - So what material you recommend to start a study in rSpec? >> > > This might be heresy, but I suggest that you start with Cucumber and > simply use RSpec matcher syntax in your step definitions.   Once y

Re: [rspec-users] rspec-users Digest, Vol 34, Issue 2

2009-04-01 Thread Charleno Pires
e a lot of code out there at this basic a level. > > Any ideas? > > Scott > > On Wed, Apr 1, 2009 at 6:57 AM, Stephen Eley wrote: > >> 2009/4/1 Pablo L. de Miranda : >> > @Fernando - So what material you recommend to start a study in rSpec? >> >> 1.) The W

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread James Byrne
Pablo L. de Miranda wrote: > @Fernando - So what material you recommend to start a study in rSpec? > This might be heresy, but I suggest that you start with Cucumber and simply use RSpec matcher syntax in your step definitions. Once you have the hang of how to express expectations in the step

Re: [rspec-users] rspec-users Digest, Vol 34, Issue 2

2009-04-01 Thread Charleno Pires
e a lot of code out there at this basic a level. > > Any ideas? > > Scott > > On Wed, Apr 1, 2009 at 6:57 AM, Stephen Eley wrote: > >> 2009/4/1 Pablo L. de Miranda : >> > @Fernando - So what material you recommend to start a study in rSpec? >> >> 1.) The W

Re: [rspec-users] rspec-users Digest, Vol 34, Issue 2

2009-04-01 Thread Charleno Pires
e a lot of code out there at this basic a level. > > Any ideas? > > Scott > > On Wed, Apr 1, 2009 at 6:57 AM, Stephen Eley wrote: > >> 2009/4/1 Pablo L. de Miranda : >> > @Fernando - So what material you recommend to start a study in rSpec? >> >> 1.) The W

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Scott LaBounty
David, That's more what I was looking for. Thanks, Scott On Wed, Apr 1, 2009 at 8:44 AM, David Chelimsky wrote: > 2009/4/1 Scott LaBounty : > > I've looked at the web site and I guess I'm looking for more examples. > I'd > > like to see some simple basic ruby code and then some rSpec code test

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread David Chelimsky
2009/4/1 Scott LaBounty : > I've looked at the web site and I guess I'm looking for more examples. I'd > like to see some simple basic ruby code and then some rSpec code testing it. > No Rails, no nothing else. I haven't tried the book yet, but there does not > seem to be a lot of code out there at

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Scott LaBounty
I've looked at the web site and I guess I'm looking for more examples. I'd like to see some simple basic ruby code and then some rSpec code testing it. No Rails, no nothing else. I haven't tried the book yet, but there does not seem to be a lot of code out there at this basic a level. Any ideas?

Re: [rspec-users] RSpec makes me want to write better code

2009-04-01 Thread David Chelimsky
On Wed, Apr 1, 2009 at 8:01 AM, aidy lewis wrote: > Hi David > > 2009/3/31 David Chelimsky : > >> The point of TDD is writing small examples and small bits of code in a >> cycle. The point of BDD is to write high level scenarios so you know >> what code to write, but then drive it out in detail wi

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Stephen Eley
2009/4/1 Pablo L. de Miranda : > @Fernando - So what material you recommend to start a study in rSpec? 1.) The Web site documentation at http://rspec.info 2.) Use it and build experience. 3.) Get the beta of the RSpec book. 4.) Use it and build experience. 5.) Google is your friend. 6.) Use i

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Stephen Eley
On Tue, Mar 31, 2009 at 11:50 PM, Fernando Perez wrote: > > I don't spec at all the way he shows, I might be doing things wrong, but > I am very happy with my workflow. http://www.kipling.org.uk/poems_neolithic.htm (The poem's by Rudyard Kipling, if the URL doesn't make it clear.) -- Have Fun

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Dipen Bhanushali
Hi All, I think New user for rspec once need to see the peepcode videos. It is very helpful for the starter to understand how the rspec is working. Other wise the http://rspec.info documentation is providing the good information for any rails developer to use and test it in the application. Thank

Re: [rspec-users] RSpec makes me want to write better code

2009-04-01 Thread aidy lewis
Hi David 2009/3/31 David Chelimsky : > The point of TDD is writing small examples and small bits of code in a > cycle. The point of BDD is to write high level scenarios so you know > what code to write, but then drive it out in detail with TDD. Does this necessitate that the same person or pair

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Pablo L. de Miranda
@Fernando - So what material you recommend to start a study in rSpec? Att, Pablo Lacerda de Miranda pablolmira...@gmail.com ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] Good introduction to rspec

2009-04-01 Thread Fernando Perez
> http://peepcode.com/products/rspec-basics > http://peepcode.com/products/rspec-mocks-and-models > http://peepcode.com/products/rspec-controllers-and-tools > I didn't like at all the peepcode episodes on RSpec. You'll have to rewrite his valid_attributes trick from scratch if your models use a