Re: [rspec-users] ZenTest Autotest and 1.1.5

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 9:30 PM, Donald French <[EMAIL PROTECTED]> wrote: > I have been using ZenTest AutoTest with the previous version of rspec-rails. > When I updated to 1.1.5 the autotest just hangs. Are these compatible? Use either the installed autospec (not autotest) or script/autospec comm

[rspec-users] ZenTest Autotest and 1.1.5

2008-09-29 Thread Donald French
I have been using ZenTest AutoTest with the previous version of rspec- rails. When I updated to 1.1.5 the autotest just hangs. Are these compatible? Don French ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listin

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread Nick Hoffman
On 2008-09-29, at 19:33, Zach Dennis wrote: Having chained_replace_html is a hack to separate the regular expressions based on if you used Way #1 or Way #2. Interesting. Thanks for that explanation. I have stopped relying on using RJS selectors to test against generated JavaScript. I have als

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread Nick Hoffman
On 2008-09-29, at 13:19, Steve Schafer wrote: I think it's a parsing problem, rather than an idiom problem. I think he read it as if "offhand" were the object of "that is offhand," which doesn't make much sense. Hah, you're right, Steve =) ___ rspe

Re: [rspec-users] expect_render

2008-09-29 Thread Scott Taylor
On Sep 29, 2008, at 5:02 PM, David Chelimsky wrote: On Mon, Sep 29, 2008 at 3:51 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: On Sep 29, 2008, at 4:36 PM, David Chelimsky wrote: On Mon, Sep 29, 2008 at 3:30 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: On Sep 29, 2008, at 3:54 PM, David Chel

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread Zach Dennis
On Sun, Sep 28, 2008 at 11:59 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote: > On 2008-09-28, at 17:20, Nick Hoffman wrote: >> >> 431 it 'should hide the map filter errors ' do >> 432 do_xhr @xhr_params >> 433 response.should have_rjs >> 434 # response.should have_

Re: [rspec-users] expect_render

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 3:51 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: > > On Sep 29, 2008, at 4:36 PM, David Chelimsky wrote: > >> On Mon, Sep 29, 2008 at 3:30 PM, Scott Taylor >> <[EMAIL PROTECTED]> wrote: >>> >>> On Sep 29, 2008, at 3:54 PM, David Chelimsky wrote: >>> On Mon, Sep 29, 2008

Re: [rspec-users] expect_render

2008-09-29 Thread Scott Taylor
On Sep 29, 2008, at 4:36 PM, David Chelimsky wrote: On Mon, Sep 29, 2008 at 3:30 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: On Sep 29, 2008, at 3:54 PM, David Chelimsky wrote: On Mon, Sep 29, 2008 at 2:52 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: I'm trying to write a spec asserting th

Re: [rspec-users] expect_render

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 3:30 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: > > On Sep 29, 2008, at 3:54 PM, David Chelimsky wrote: > >> On Mon, Sep 29, 2008 at 2:52 PM, Scott Taylor >> <[EMAIL PROTECTED]> wrote: >>> >>> I'm trying to write a spec asserting that no layout should be used in a >>> contr

Re: [rspec-users] expect_render

2008-09-29 Thread Scott Taylor
On Sep 29, 2008, at 3:54 PM, David Chelimsky wrote: On Mon, Sep 29, 2008 at 2:52 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: I'm trying to write a spec asserting that no layout should be used in a controller. My spec currently looks like this: it "should render with no layout" do c

Re: [rspec-users] expect_render

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 2:52 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: > > I'm trying to write a spec asserting that no layout should be used in a > controller. My spec currently looks like this: > >it "should render with no layout" do > controller.expect_render.with(hash_including(:lay

[rspec-users] expect_render

2008-09-29 Thread Scott Taylor
I'm trying to write a spec asserting that no layout should be used in a controller. My spec currently looks like this: it "should render with no layout" do controller.expect_render.with(hash_including(:layout => nil)) do_action end And this code, which should pass the s

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread Steve Schafer
On Mon, 29 Sep 2008 11:34:34 -0500, you wrote: >On Mon, Sep 29, 2008 at 10:51 AM, Nick Hoffman <[EMAIL PROTECTED]> wrote: >> On 2008-09-29, at 07:58, David Chelimsky wrote: >>> ... >>> >>> I'm not sure why that is offhand, still waking up this fine Monday >>> morning, but I'd recommend throwing th

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 10:51 AM, Nick Hoffman <[EMAIL PROTECTED]> wrote: > On 2008-09-29, at 07:58, David Chelimsky wrote: >> >> On Sun, Sep 28, 2008 at 10:59 PM, Nick Hoffman <[EMAIL PROTECTED]> >> wrote: >>> >>> On 2008-09-28, at 17:20, Nick Hoffman wrote: 431 it 'should hide t

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread Nick Hoffman
On 2008-09-29, at 07:58, David Chelimsky wrote: On Sun, Sep 28, 2008 at 10:59 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote: On 2008-09-28, at 17:20, Nick Hoffman wrote: 431 it 'should hide the map filter errors ' do 432 do_xhr @xhr_params 433 response.should have_rjs

Re: [rspec-users] rake spec defaults to devel env

2008-09-29 Thread Tero Tilus
2008-09-26 20:19, Jonathan Linowes: > rake spec looks at the development environment to prepare the db > schema, but still runs the specs in test Looks like you're right. I haven't really had time to test this though. I'll tell when I really know whats going on inside our app. -- Tero Tilus ##

Re: [rspec-users] [ANN] RSpec-1.1.5 has been released

2008-09-29 Thread Mikel Lindsaar
On Mon, Sep 29, 2008 at 9:01 PM, Scott Taylor <[EMAIL PROTECTED]> wrote: Nice :) -- http://lindsaar.net/ Rails, RSpec and Life blog ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] Lot's o' questions about Cucumbert

2008-09-29 Thread aslak hellesoy
On Mon, Sep 29, 2008 at 3:14 PM, Fernando Perez <[EMAIL PROTECTED]> wrote: > Thanks Dave, I am starting to understand better the workflow to adopt > with cucumber and webrat. > > By the way I am having some issues with the: I should see "..." regexp. > If what I want to see has double quotes or bra

Re: [rspec-users] Lot's o' questions about Cucumbert

2008-09-29 Thread Fernando Perez
Thanks Dave, I am starting to understand better the workflow to adopt with cucumber and webrat. By the way I am having some issues with the: I should see "..." regexp. If what I want to see has double quotes or brackets, it seems to fail and not properly detect the string. -- Posted via http:/

Re: [rspec-users] Why no rspec-rails gem?

2008-09-29 Thread David Chelimsky
On Sun, Sep 28, 2008 at 3:54 PM, Pat Maddox <[EMAIL PROTECTED]> wrote: > Tim Harper <[EMAIL PROTECTED]> writes: > >> I was getting a little tired of adding 2 plugins every time I create a >> new rails project, so I just built an rspec-rails gemspec, and it >> works perfectly well. Does anybody kno

Re: [rspec-users] Best way to determine if RSpec is loaded?

2008-09-29 Thread David Chelimsky
On Sun, Sep 28, 2008 at 6:54 PM, Ashley Moran <[EMAIL PROTECTED]> wrote: > Hi > > I've been using the Twitter gem, but I discovered it loads ActiveSupport, > which meddles with Kernel#require and generally causes me confusion and > pain. I don't need Twitter loaded for my specs, currently I'm doin

Re: [rspec-users] Not seeing an RJS change

2008-09-29 Thread David Chelimsky
On Sun, Sep 28, 2008 at 10:59 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote: > On 2008-09-28, at 17:20, Nick Hoffman wrote: >> >> 431 it 'should hide the map filter errors ' do >> 432 do_xhr @xhr_params >> 433 response.should have_rjs >> 434 # response.should have_

Re: [rspec-users] Problems mocking controller helpers with the last version.

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 6:35 AM, Juanma Cervera <[EMAIL PROTECTED]> wrote: > Thanks Craig, but I think I don't understand completely. > > "current_user" is a helper method provided by the plugin > restful_authentication > to access the @current_user variable as I understand. > It is defined in lib/

Re: [rspec-users] Lot's o' questions about Cucumbert

2008-09-29 Thread David Chelimsky
On Mon, Sep 29, 2008 at 5:10 AM, Fernando Perez <[EMAIL PROTECTED]> wrote: >> Is there a way to skip database initialization? Because it takes too >> much time to run each test. > So do you handle data inside the testing environment. Let's say: Given > there are 2 products available on the site. >

Re: [rspec-users] Problems mocking controller helpers with the last version.

2008-09-29 Thread Juanma Cervera
Thanks Craig, but I think I don't understand completely. "current_user" is a helper method provided by the plugin restful_authentication to access the @current_user variable as I understand. It is defined in lib/authenticated_system.rb. We use this helper to access the current logged-in user in t

Re: [rspec-users] Lot's o' questions about Cucumbert

2008-09-29 Thread David Chelimsky
On Sun, Sep 28, 2008 at 4:24 PM, Fernando Perez <[EMAIL PROTECTED]> wrote: > Thank you David, > > Is there a way to skip database initialization? Because it takes too > much time to run each test. Is there a similar way to mock objects or > create objects and have them "saved" in memory? I don't un

Re: [rspec-users] Problems mocking controller helpers with the last version.

2008-09-29 Thread Craig Demyanovich
I can't tell from your post whether you meant to type an instance or local variable when noting that you "could check the role of the user in the view with current_user.role," since you mentioned an instance variable earlier. assigns[:current_user] = ... sets up an instance variable, @current_user

Re: [rspec-users] Problems mocking controller helpers with the last version.

2008-09-29 Thread Juanma Cervera
Well, it seems pretty obvious that I can't use "controller" to mock controller methods in the view specs, but I was assigning a mock for the current logged-in user to the @current_user variable and it worked on rspec 1.1.4 I was doing this: assigns[:current_user] = stub_model(User, :role => "w

Re: [rspec-users] [ANN] RSpec-1.1.5 has been released

2008-09-29 Thread Scott Taylor
On Sep 29, 2008, at 2:26 AM, Mikel Lindsaar wrote: On Mon, Sep 29, 2008 at 12:07 PM, David Chelimsky <[EMAIL PROTECTED] > wrote: RSpec-1.1.5 has been released rspec_team.should_receive(:thank_you).at_least(:once) GmailMailer.post(email) class GmailMailer class << self def post(email)

Re: [rspec-users] rspec-ui overlap with cucumber?

2008-09-29 Thread Priit Tamboom
Wow, thanks for fast replies! > rspec-ui is defunct - as far as i am concerned. none seems to be > maintaining it, and cucumber should replace it. Yep, feels so. > I'm not sure I understand what there is to "support" about it. You can > use anything inside Cucumber step definitions - Cucumber sh

Re: [rspec-users] Lot's o' questions about Cucumbert

2008-09-29 Thread Fernando Perez
> Is there a way to skip database initialization? Because it takes too > much time to run each test. So do you handle data inside the testing environment. Let's say: Given there are 2 products available on the site. Currently I am using 1.upto(2) do |i|; Product.create!(:title => "title#{i}"..

Re: [rspec-users] rspec-ui overlap with cucumber?

2008-09-29 Thread Joseph Wilk
Priit Tamboom wrote: Hi! I'm using cucumber + selenium and I love it. However I'm looking to add some methods (example: click_and_wait etc) to the lib. Therefore looked around a bit and I got two questions: Firstly about rspec-ui, I'm a little confused, does rspec-ui overlap with its propose wi

Re: [rspec-users] rspec-ui overlap with cucumber?

2008-09-29 Thread aslak hellesoy
On Mon, Sep 29, 2008 at 11:29 AM, Priit Tamboom <[EMAIL PROTECTED]> wrote: > Hi! > > I'm using cucumber + selenium and I love it. However I'm looking to > add some methods (example: click_and_wait etc) to the lib. Therefore > looked around a bit and I got two questions: > > Firstly about rspec-ui,

[rspec-users] Problems mocking controller helpers with the last version.

2008-09-29 Thread Juanma Cervera
I have just installed the edge version of rspec and rspec-rails and some of my specs related to views now fail. I use the helper current_user in my views, to access the user that is actually logged in. I was simply using the sentence assigns[:current_user] = stub_model(User,:role => "whatever") a

[rspec-users] rspec-ui overlap with cucumber?

2008-09-29 Thread Priit Tamboom
Hi! I'm using cucumber + selenium and I love it. However I'm looking to add some methods (example: click_and_wait etc) to the lib. Therefore looked around a bit and I got two questions: Firstly about rspec-ui, I'm a little confused, does rspec-ui overlap with its propose with webrat with cucumber

Re: [rspec-users] webrat the way to go?

2008-09-29 Thread Willem van den Ende
On Mon, 2008-09-29 at 09:57 +0200, aslak hellesoy wrote: > > > Try to replace Subject with for="invitation_subject">Subject > Now both vision impaired people and Webrat know that the text > "Subject" is linked to the input field. This is much better semantic > HTML. Ah, thanks. I'll do that. I

Re: [rspec-users] webrat the way to go?

2008-09-29 Thread aslak hellesoy
On Mon, Sep 29, 2008 at 9:07 AM, Willem van den Ende <[EMAIL PROTECTED]> wrote: > Hi Aslak, > > thanks for responding (more below). > > On Mon, 2008-09-29 at 08:48 +0200, aslak hellesoy wrote: >> On Mon, Sep 29, 2008 at 8:46 AM, Willem van den Ende >> <[EMAIL PROTECTED]> wrote: >> > On Sun, 2008-09

Re: [rspec-users] webrat the way to go?

2008-09-29 Thread Willem van den Ende
Hi Aslak, thanks for responding (more below). On Mon, 2008-09-29 at 08:48 +0200, aslak hellesoy wrote: > On Mon, Sep 29, 2008 at 8:46 AM, Willem van den Ende > <[EMAIL PROTECTED]> wrote: > > On Sun, 2008-09-28 at 22:24 +0200, Willem van den Ende wrote: > > > >> When I go to invitation/new, I see