Re: [rspec-users] rspec 2 not cleaning up after examples run?

2010-07-01 Thread Timo Rößner
@David, alright, I tried: bundle exec rspec spec/models/challenge_spec.rb - Same results, same log output as above. @Amiruddin script/spec would be rails 2 / rspec 1 - my problem occurs with rails 3 / rspec 2 (and script/spec doesn't exist because of that). On Jun 30, 7:44 pm, Amiruddin

Re: [rspec-users] rspec 2 not cleaning up after examples run?

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 3:22 AM, Timo Rößner wrote: On Jun 30, 7:44 pm, Amiruddin Nagri amir.na...@gmail.com wrote: I am not sure if this will help or not but I was also getting data not cleared properly when run specs through rake but when ran using script/spec it was cleaning up the data

Re: [rspec-users] Rake spec options

2010-07-01 Thread Ibrahim Awwal
On Jul 1, 9:13 am, Ibrahim Awwal ibrahim.aw...@gmail.com wrote: Hi guys, Apologies if this is a dumb question. I'm new to rails and most of the information online is about rails 2 and rspec 1.3, but my group is using rails 3 and thus rspec 2. I'm trying to format the output of rake spec, and

Re: [rspec-users] Rake spec options

2010-07-01 Thread Ibrahim Awwal
On Jul 1, 9:25 am, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 11:13 AM, Ibrahim Awwal wrote: Hi guys, Apologies if this is a dumb question. I'm new to rails and most of the information online is about rails 2 and rspec 1.3, but my group is using rails 3 and thus

Re: [rspec-users] Rake spec options

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 11:41 AM, Ibrahim Awwal wrote: On Jul 1, 9:25 am, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 11:13 AM, Ibrahim Awwal wrote: Hi guys, Apologies if this is a dumb question. I'm new to rails and most of the information online is about rails 2 and

Re: [rspec-users] using LINE with nested example groups

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 1:27 PM, Arco wrote: I would like to use the --line parameter with nested example groups (describe / context). It looks to me like rspec handles this fine if I select the innermost group. But if I select an outer group, rspec ignores all the nested examples. Is this

[rspec-users] Cookie assignment and reading

2010-07-01 Thread Josh Clayton
Hello all, I'm running the latest stable rspec/rspec-rails (1.3.0/1.3.2) in a Rails 2.3.8 app and am having trouble testing that a cookie gets deleted. In a semi-convoluted manner, I am essentially running code from the rdoc as such: describe MyController, GET index do

[rspec-users] How to test index method of a controller ?

2010-07-01 Thread marcioa1
Hi, My index methods def index @galleries = Gallery.filtered_by(params.reverse_merge!(:per_page = 10)) end My spec: it should list all galleries do get :index response.should render_template(index) end And the error message should list all

[rspec-users] Entering text into a text field using rspec

2010-07-01 Thread tester86
HI I am new to rspec. I am at a web page and in that page I want to enter in some text and then click send. it will enter in some text 'asf' do end what command would I used to enter in the text as I have searched google but I cannot find any thing helpful. I do not want to use watir as it

[rspec-users] Shoulda and explicit subject

2010-07-01 Thread ericindc
I am trying to use Shoulda matchers with the latest beta version of RSpec for Rails 3. I've managed to track down the cause of my errors to needing to explicitly set the subject, but the Shoulda examples make no mention of requiring this step. I've pastied the errors I'm receiving and adding

[rspec-users] Rspec-rails 2 and spec/spec.opts or other configuration options for rake spec

2010-07-01 Thread Ibrahim Awwal
Hi guys, I apologize if this is a dumb question, but in rspec-rails version 2.0.0.14 (for rails 3.0.0b4) I'm trying to add configuration options like some tutorials mention in a file spec/spec.opts, but this has no effect. I glanced through the source of rspec and I couldn't find anything where it

Re: [rspec-users] Entering text into a text field using rspec

2010-07-01 Thread Curtis
Check into capybara On Jun 29, 2010, at 4:44 PM, tester86 sagar.am...@gmail.com wrote: HI I am new to rspec. I am at a web page and in that page I want to enter in some text and then click send. it will enter in some text 'asf' do end what command would I used to enter in the text as I

Re: [rspec-users] Rspec-rails 2 and spec/spec.opts or other configuration options for rake spec

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 1:52 AM, Ibrahim Awwal wrote: Hi guys, I apologize if this is a dumb question, but in rspec-rails version 2.0.0.14 (for rails 3.0.0b4) I'm trying to add configuration options like some tutorials mention in a file spec/spec.opts, but this has no effect. I glanced through

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread David Chelimsky
On Jun 30, 2010, at 12:00 PM, ericindc wrote: I am trying to use Shoulda matchers with the latest beta version of RSpec for Rails 3. I've managed to track down the cause of my errors to needing to explicitly set the subject, but the Shoulda examples make no mention of requiring this step.

Re: [rspec-users] Entering text into a text field using rspec

2010-07-01 Thread Curtis
On Jun 29, 2010, at 4:44 PM, tester86 sagar.am...@gmail.com wrote: HI I am new to rspec. I am at a web page and in that page I want to enter in some text and then click send. Sorry - toppost is a habit - check out capybara and see how it can be used stand alone with rspec to interact

Re: [rspec-users] How to test index method of a controller ?

2010-07-01 Thread David Chelimsky
On Jun 29, 2010, at 5:08 PM, marcioa1 wrote: Hi, My index methods def index @galleries = Gallery.filtered_by(params.reverse_merge!(:per_page = 10)) end My spec: it should list all galleries do get :index response.should

Re: [rspec-users] Cookie assignment and reading

2010-07-01 Thread David Chelimsky
On Jun 29, 2010, at 4:05 PM, Josh Clayton wrote: Hello all, I'm running the latest stable rspec/rspec-rails (1.3.0/1.3.2) in a Rails 2.3.8 app and am having trouble testing that a cookie gets deleted. In a semi-convoluted manner, I am essentially running code from the rdoc as such:

Re: [rspec-users] Rake spec options

2010-07-01 Thread Ibrahim Awwal
On Jul 1, 11:06 am, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 11:41 AM, Ibrahim Awwal wrote: On Jul 1, 9:25 am, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 11:13 AM, Ibrahim Awwal wrote: Hi guys, Apologies if this is a dumb question. I'm new to

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread ericindc
I have a thread open on their group page as well, but the only response received thus far seems to think it's an RSpec issue. I am having the same issue in my model tests as well. On Jul 1, 3:23 pm, David Chelimsky dchelim...@gmail.com wrote: On Jun 30, 2010, at 12:00 PM, ericindc wrote: I

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 8:40 PM, ericindc wrote: On Jul 1, 3:23 pm, David Chelimsky dchelim...@gmail.com wrote: On Jun 30, 2010, at 12:00 PM, ericindc wrote: I am trying to use Shoulda matchers with the latest beta version of RSpec for Rails 3. I've managed to track down the cause of my errors

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread ericindc
http://groups.google.com/group/shoulda/browse_thread/thread/9a19ca5f60285e2d On Jul 1, 9:47 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 8:40 PM, ericindc wrote: On Jul 1, 3:23 pm, David Chelimsky dchelim...@gmail.com wrote: On Jun 30, 2010, at 12:00 PM, ericindc

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 9:01 PM, ericindc wrote: On Jul 1, 9:47 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 8:40 PM, ericindc wrote: On Jul 1, 3:23 pm, David Chelimsky dchelim...@gmail.com wrote: On Jun 30, 2010, at 12:00 PM, ericindc wrote: I am trying to use Shoulda

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread ericindc
Here is the full controller spec that is passing...removing the subject line fails all bu the render_template. require 'spec_helper' describe HomepageController do describe routes do it { should route(:get, /).to(:action = :index) } end describe on GET to :index do before(:each)

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 9:35 PM, ericindc wrote: On Jul 1, 10:32 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 9:01 PM, ericindc wrote: On Jul 1, 9:47 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 8:40 PM, ericindc wrote: On Jul 1, 3:23 pm,

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread ericindc
Will do, thanks! On Jul 1, 11:10 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 9:35 PM, ericindc wrote: On Jul 1, 10:32 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 9:01 PM, ericindc wrote: On Jul 1, 9:47 pm, David Chelimsky

Re: [rspec-users] Shoulda and explicit subject

2010-07-01 Thread David Chelimsky
On Jul 1, 2010, at 10:32 PM, ericindc wrote: On Jul 1, 11:10 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 9:35 PM, ericindc wrote: On Jul 1, 10:32 pm, David Chelimsky dchelim...@gmail.com wrote: On Jul 1, 2010, at 9:01 PM, ericindc wrote: On Jul 1, 9:47 pm, David

Re: [rspec-users] using rSpec stub in Cucumber with rSpec2

2010-07-01 Thread Florent Florent
Hello, I have a Rails3beta4 project where I want to use rSpec stubs in a Cucumber feature. Unfortunately it looks like requiring 'spec/stubs/cucumber' in env.rb does not work anymore: I get a no such file to load -- spec/stubs/cucumber (LoadError) error. Is it possible to use rSpec stubs

Re: [rspec-users] RSpec 2.0, Cucumber, ruby-debug

2010-07-01 Thread Woody Peterson
What are you experiencing and what are you expecting? If you use rspec in cucumber, cucumber doesn't support --debug as an option, so you can't use debuggers in cucumber + rspec. Given RSpec 2.0's api, the expected behavior is declaring --debug + debugger drops you into a debugger, and the