Re: [rspec-users] undefined method `inherit' for Merb::Test::ExampleGroup

2009-02-02 Thread David Chelimsky
On Mon, Feb 2, 2009 at 10:36 PM, Phlip wrote: > Pat Maddox wrote: > >> I'll blame Merb on the basis that there is no "inherit" in RSpec. I'm >> guessing it's some kind of merb extension. > > http://blog.davidchelimsky.net/2007/4/1/rspec-plays-nice-with-others > > I know I know - time flies! > > I

Re: [rspec-users] undefined method `inherit' for Merb::Test::ExampleGroup

2009-02-02 Thread Pat Maddox
On Mon, Feb 2, 2009 at 8:36 PM, Phlip wrote: > Pat Maddox wrote: > >> I'll blame Merb on the basis that there is no "inherit" in RSpec. I'm >> guessing it's some kind of merb extension. > > http://blog.davidchelimsky.net/2007/4/1/rspec-plays-nice-with-others > > I know I know - time flies! > > If

Re: [rspec-users] undefined method `inherit' for Merb::Test::ExampleGroup

2009-02-02 Thread Phlip
Pat Maddox wrote: I'll blame Merb on the basis that there is no "inherit" in RSpec. I'm guessing it's some kind of merb extension. http://blog.davidchelimsky.net/2007/4/1/rspec-plays-nice-with-others I know I know - time flies! If it has been superseded, then how do you inject a batch of as

Re: [rspec-users] undefined method `inherit' for Merb::Test::ExampleGroup

2009-02-02 Thread Pat Maddox
I'll blame Merb on the basis that there is no "inherit" in RSpec. I'm guessing it's some kind of merb extension. Pat On Mon, Feb 2, 2009 at 6:19 PM, Phlip wrote: > I have to bump this one because it looks like it's on RSpec's core feature > list, and I reeally need a fix for it. > > Feel free

[rspec-users] undefined method `inherit' for Merb::Test::ExampleGroup

2009-02-02 Thread Phlip
I have to bump this one because it looks like it's on RSpec's core feature list, and I reeally need a fix for it. Feel free to blame Merb, if they munged the inherit() method somehow! Here's the relevant bits that don't work. (I changed the goal library to the 'assert2' patched into Test::Unit

Re: [rspec-users] Trouble validating an exception

2009-02-02 Thread Pat Maddox
On Mon, Feb 2, 2009 at 3:30 PM, Ben Greenberg wrote: > Hi all, > > This spec always passes: > >lambda do > process_card @credit_card, billing_info, 10604, '1.1.1.1', @gateway >end.should raise_error(MinimalCart::CaptureFailureError) do |ex| > ex.should be_nil > ex.should_not

Re: [rspec-users] Trouble validating an exception

2009-02-02 Thread Scott Taylor
On Feb 2, 2009, at 6:30 PM, Ben Greenberg wrote: Hi all, This spec always passes: lambda do process_card @credit_card, billing_info, 10604, '1.1.1.1', @gateway end.should raise_error(MinimalCart::CaptureFailureError) do |ex| ex.should be_nil ex.should_not be_nil e

Re: [rspec-users] Trouble validating an exception

2009-02-02 Thread Pat Maddox
On Mon, Feb 2, 2009 at 4:22 PM, Pat Maddox wrote: > On Mon, Feb 2, 2009 at 3:30 PM, Ben Greenberg > wrote: >> Hi all, >> >> This spec always passes: >> >>lambda do >> process_card @credit_card, billing_info, 10604, '1.1.1.1', @gateway >>end.should raise_error(MinimalCart::CaptureFail

Re: [rspec-users] Trouble validating an exception

2009-02-02 Thread Scott Taylor
On Feb 2, 2009, at 6:30 PM, Ben Greenberg wrote: Hi all, This spec always passes: lambda do process_card @credit_card, billing_info, 10604, '1.1.1.1', @gateway end.should raise_error(MinimalCart::CaptureFailureError) do |ex| ex.should be_nil ex.should_not be_nil e

[rspec-users] Trouble validating an exception

2009-02-02 Thread Ben Greenberg
Hi all, This spec always passes: lambda do process_card @credit_card, billing_info, 10604, '1.1.1.1', @gateway end.should raise_error(MinimalCart::CaptureFailureError) do |ex| ex.should be_nil ex.should_not be_nil ex.responses.should be_nil ex.responses.shou

Re: [rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread Ben Mabey
r_j_h_box...@yahoo.com wrote: A question for edumacational purposes here: Instead of disabling transactions, would it be effective to include all the steps of inserting the record and running the search, inside one scenario? Given [the record is added to the database" When [I search for it] Th

[rspec-users] [RSpec] rcov and/or rexml bug?

2009-02-02 Thread Fernando Perez
Hi, Running: Ruby 1.8.7 p72, RSpec 1.1.12 and rcov 0.8.1.2.0, I get the following error message with $ rake spec:rcov -- /usr/local/ruby1.8.7//lib/ruby/1.8/rexml/formatters/pretty.rb:131:in `[]': no implicit conversion from nil to integer (TypeError) from /usr/local/ruby1.8.7//lib/ruby/1.

Re: [rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread Bart Zonneveld
On 2 feb 2009, at 17:00, Ben Mabey wrote: Bart Zonneveld wrote: Hey list, Anyone have experience with acts_as_xapian and Cucumber? I'm struggling with updating xapian's index, to actually "find" fluff that has been indexed.. In a scenario, I'm adding a bunch of articles, and in the actual

Re: [rspec-users] RSpec - Testing ActiveRecord addins

2009-02-02 Thread James Byrne
James Byrne wrote: > > I have one other difficulty when running this on MS-WinXPpro under > cygwin. The newline character seems to have no effect. I can force it > to behave locally by adding a \r in front of each \n but, obviously, > that will have unfortunate consequences on *nix. Actually

Re: [rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread Bart Zonneveld
On 2 feb 2009, at 18:15, r_j_h_box...@yahoo.com wrote: A question for edumacational purposes here: Instead of disabling transactions, would it be effective to include all the steps of inserting the record and running the search, inside one scenario? That is exactly what I am doing in my

Re: [rspec-users] RSpec - Testing ActiveRecord addins

2009-02-02 Thread James Byrne
James Byrne wrote: > > What is happening is that RSpec is blowing up at its own logger code in > the default spec_helper.rb file. This happens whether or not ActAsFu is > installed and whether or not my custom logger is commented out in > environment.rb I poked at this a bit and hit upon the

Re: [rspec-users] [Cucumber] --dry-run

2009-02-02 Thread aslak hellesoy
On Mon, Feb 2, 2009 at 7:00 PM, Tim Walker wrote: > Hi Guys, > > I see in the Cucmber --help that -d akd --dry-run is supported but it > doesn't seem to work. > > Anyone know why? > Because it has a bug that has been fixed in 0.2 prereleases (0.1.99.x) http://tinyurl.com/cucumber-0-2-beta Aslak

[rspec-users] [Cucumber] --dry-run

2009-02-02 Thread Tim Walker
Hi Guys, I see in the Cucmber --help that -d akd --dry-run is supported but it doesn't seem to work. Anyone know why? Thanks, very much. Tim ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] [RSpec] Cannot save or be_valid when using xss_terminate

2009-02-02 Thread Fernando Perez
> I rspec models that use xss_terminate with no problem. I have not see > the error you're getting. > > linoj Thanks. Knowing that it is possible to spec models that use xss_terminate I was able to figure out that in one of my attributes I was passing a Time object, so simply converting it to

Re: [rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread r_j_h_box-sf
A question for edumacational purposes here: Instead of disabling transactions, would it be effective to include all the steps of inserting the record and running the search, inside one scenario? Given [the record is added to the database" When [I search for it] Then [I should find it] If this

Re: [rspec-users] [RSpec] Cannot save or be_valid when using xss_terminate

2009-02-02 Thread Jonathan Linowes
On Feb 2, 2009, at 11:30 AM, Fernando Perez wrote: Hi, I have a Rails app that uses xss_terminate to sanitize the user input before it gets saved to the DB. In my specs when I call @product.should be_valid or @product.save, I get the following error message: -- NoMethodError in 'Creating a

Re: [rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread Ben Mabey
Bart Zonneveld wrote: Hey list, Anyone have experience with acts_as_xapian and Cucumber? I'm struggling with updating xapian's index, to actually "find" fluff that has been indexed.. In a scenario, I'm adding a bunch of articles, and in the actual search step, I run: When "I search for \"$q

[rspec-users] [RSpec] Cannot save or be_valid when using xss_terminate

2009-02-02 Thread Fernando Perez
Hi, I have a Rails app that uses xss_terminate to sanitize the user input before it gets saved to the DB. In my specs when I call @product.should be_valid or @product.save, I get the following error message: -- NoMethodError in 'Creating a product with all necessary attributes should be valid' und

Re: [rspec-users] [Cucumber] and rake pass command-line params

2009-02-02 Thread Andre Pretorius
Great advice, I did all the suggestions you made, and... it is GOOD and CLEAN:) Thanks Aslak On Mon, Feb 2, 2009 at 1:58 PM, aslak hellesoy wrote: > On Mon, Feb 2, 2009 at 2:24 PM, AndreXP > wrote: > > > > Hi list, > > > > I might have not asked this correctly in previous post.. and most > defi

Re: [rspec-users] [Cucumber] and rake pass command-line params

2009-02-02 Thread aslak hellesoy
On Mon, Feb 2, 2009 at 2:24 PM, AndreXP wrote: > > Hi list, > > I might have not asked this correctly in previous post.. and most definitely > weren't clear! let's try again :) > > I can't seem to find any examples of using a rake variable in the Cucumber > task. What I want to do is run my cucumb

[rspec-users] [Cucumber] and rake pass command-line params

2009-02-02 Thread AndreXP
Hi list, I might have not asked this correctly in previous post.. and most definitely weren’t clear! let’s try again :) I can’t seem to find any examples of using a rake variable in the Cucumber task. What I want to do is run my cucumber test using cruisecontrol and setting a variable in script

[rspec-users] [Cucumber] Cucumber and acts_as_xapian

2009-02-02 Thread Bart Zonneveld
Hey list, Anyone have experience with acts_as_xapian and Cucumber? I'm struggling with updating xapian's index, to actually "find" fluff that has been indexed.. In a scenario, I'm adding a bunch of articles, and in the actual search step, I run: When "I search for \"$query\"" do |query|

Re: [rspec-users] simple == with prettier error messages + good documentation

2009-02-02 Thread David Chelimsky
On Sat, Jan 31, 2009 at 12:02 PM, wrote: > Passing the it() and describe() args through to the reporting layer sounds > like a great idea. I've thought more about the reporting-levels approach. > The numeric as I postulated earlier is probably not the most useful thing. > > As a product manager,

Re: [rspec-users] resource urls only work *after* a get() in controller spec

2009-02-02 Thread Matt Wynne
On 2 Feb 2009, at 06:18, r_j_h_box...@yahoo.com wrote: Okay, following up on this item. Would you believe a workaround of (gasp) get :index, prior to expecting route-based URLs to work? (slaps That's what I was going to suggest. We have all our routing tests in a separate file (away fr