Hi all,
We did a spike last week to de-couple our view and controller tests
from the database, using NullDb. It didn't go too well. I realise that
this plugin isn't part of RSpec, but I thought others on this list
might have experiences to share.
Here's a summary of my colleague's investi
Tom Cloyd wrote:
>
> The problem is that this assumes you are working with Rails, about
> which I know little and desire to know less. I get stuck, on that page,
> at the phrase...
>
> ==When you run "script/generate cucumber" ==
>
> Huh? Is this something you do in Rails?
>
> Then there's this
I have an authentication filter on my application controller. I have the
following feature statements:
Scenario: I should be logged in to do any of this
Given we have a user named "myuser"
And the user named "myuser" logs in
When they visit the "entities" page
Then they should
On Mon, Jan 12, 2009 at 10:45 AM, James Byrne wrote:
> I have an authentication filter on my application controller. I have the
> following feature statements:
>
>
> Scenario: I should be logged in to do any of this
>Given we have a user named "myuser"
> And the user named "myuser" logs
On 1/12/09 7:09 AM, Matt Wynne wrote:
Hi all,
We did a spike last week to de-couple our view and controller tests
from the database, using NullDb. It didn't go too well. I realise that
this plugin isn't part of RSpec, but I thought others on this list
might have experiences to share.
Here's
David Chelimsky wrote:
>
> Each scenario operates in a new session.
>
> I usually have a step that aggregates the login process:
>
> Given /^I am logged in as "(.*)"/ do |role|
> #create a user whose name and role are based on the role
> #log in that user
> end
>
> This lets me say:
>
> G
On Mon, Jan 12, 2009 at 6:21 PM, David Chelimsky wrote:
> On Mon, Jan 12, 2009 at 10:45 AM, James Byrne
> wrote:
> > I have an authentication filter on my application controller. I have the
> > following feature statements:
> >
> >
> > Scenario: I should be logged in to do any of this
> >Giv
Aslak Hellesøy wrote:
> On Mon, Jan 12, 2009 at 6:21 PM, David Chelimsky
> wrote:
>
>> >Then they should see the "entities" page
>> >Then I should save the entity information successfully
>> > response.body.should =~ /Add a New Entity/m
>>
> And coupling scenarios (or any kind of automat
On Mon, Jan 12, 2009 at 1:47 PM, James Byrne wrote:
>
> At the start of every scenario, but is there no way of performing the
> actual log in once, place the session info into an instance variable and
> then use that rather than actually starting up a new session each and
> every time?
Sure. You
Stephen Eley wrote:
>
> On acceptance testing, I'd favor going through the actual session
> creation logic instead of mocking it, even if you don't put an
> explicit "Given" every time. Yeah, it's slower. But acceptance tests
> aren't _supposed_ to be fast; they're supposed to demonstrate real
On 12 Jan 2009, at 17:36, Ben Mabey wrote:
On 1/12/09 7:09 AM, Matt Wynne wrote:
Hi all,
We did a spike last week to de-couple our view and controller tests
from the database, using NullDb. It didn't go too well. I realise
that this plugin isn't part of RSpec, but I thought others on this
On 1/12/09 1:05 PM, Matt Wynne wrote:
On 12 Jan 2009, at 17:36, Ben Mabey wrote:
On 1/12/09 7:09 AM, Matt Wynne wrote:
Hi all,
We did a spike last week to de-couple our view and controller tests
from the database, using NullDb. It didn't go too well. I realise
that this plugin isn't part o
This is giving me an error:
When /?:(log|sign)?:(i|o)n success message/ do
Then "welcome message"
end
To the effect that:
/usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require':
./features/components/login/step_definitions/login_steps.rb:21: invalid
regular express
This is giving me an error:
When /?:(log|sign)?:(i|o)n success message/ do
Then "welcome message"
end
I could be wrong, but I believe you're looking for this instead?
When /(?:log|sign)(?:i|o)n success message/ do
hope that helps,
timg
___
rspec-u
On 1/12/09 2:50 PM, James Byrne wrote:
This is giving me an error:
When /?:(log|sign)?:(i|o)n success message/ do
Then "welcome message"
end
The ?: needs to be inside your group if you don't want to capture it... so:
When /(?:log|sign)(?:i|o)n success message/ do
FWIW, I have found ht
On Mon, Jan 12, 2009 at 4:50 PM, James Byrne wrote:
>
> When /?:(log|sign)?:(i|o)n success message/ do
> Then "welcome message"
> end
It's a syntax error on that first question mark, the one right after
the slash. A ? in a regex signifies that whatever came just before it
may appear 0 or 1 time
I gather from some recent posts that some people are actually using
NullDB in their projects. As the creator of NullDB, I'm pleased and a
little surprised to hear this.
Since NullDB is has received exactly zero attention from me since
it's initial release, I'm curious how it's working out for pe
On Mon, Jan 12, 2009 at 11:35 PM, Tim Glen wrote:
>
>> This is giving me an error:
>>
>> When /?:(log|sign)?:(i|o)n success message/ do
>> Then "welcome message"
>> end
>>
>
>
> I could be wrong, but I believe you're looking for this instead?
> When /(?:log|sign)(?:i|o)n success message/ do
>
A
On 1/12/09 4:20 PM, Avdi Grimm wrote:
I gather from some recent posts that some people are actually using
NullDB in their projects. As the creator of NullDB, I'm pleased and a
little surprised to hear this.
Since NullDB is has received exactly zero attention from me since
it's initial release,
On Mon, Jan 12, 2009 at 3:20 PM, Avdi Grimm wrote:
> I gather from some recent posts that some people are actually using
> NullDB in their projects. As the creator of NullDB, I'm pleased and a
> little surprised to hear this.
>
> Since NullDB is has received exactly zero attention from me since
On Mon, Jan 12, 2009 at 11:49 AM, James Byrne wrote:
> Stephen Eley wrote:
>
>>
>> On acceptance testing, I'd favor going through the actual session
>> creation logic instead of mocking it, even if you don't put an
>> explicit "Given" every time. Yeah, it's slower. But acceptance tests
>> aren't
21 matches
Mail list logo