how about "factory"?
or something along that metaphor
"assemblies"
... "erections"? maybe not...
:)
On Oct 17, 2007, at 1:33 AM, John W. Long wrote:
> On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
>> I would recommend that you rename it, because "Scenario" already
>> has a
>> precise me
On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
> I would recommend that you rename it, because "Scenario" already has a
> precise meaning and plays a very important role in RSpec.
I can certainly understand why you would say that. The name is
inspired by another project mentioned on ErrTheBlog
On 10/16/07, Andy Watts <[EMAIL PROTECTED]> wrote:
> I recently spent a lot of time looking at something similar before going
> with the fixtures replacement plugin.
> It gives me new_user, create_user, create_user(:first_name =>
> 'overriddefault' ).
> Also creates records for associations where r
On 10/17/07, Jonathan Linowes <[EMAIL PROTECTED]> wrote:
> Hi,
>
> This is weird
>
> All my current spec examples are passing (about 750 of 'em) except a
> set of 6 in a specific controller spec. I get the following failure
> on each 6 when I run it via
> $ rake spec
Do you have --reverse in y
btw I just noticed the text of the example is a typo, it -is- a GET
called in the spec with
get :accept, :project_id => @project.id, :id => @mem.id
On Oct 17, 2007, at 1:01 AM, Jonathan Linowes wrote:
> Hi,
>
> This is weird
>
> All my current spec examples are passing (about 750 of 'em)
Hi,
This is weird
All my current spec examples are passing (about 750 of 'em) except a
set of 6 in a specific controller spec. I get the following failure
on each 6 when I run it via
$ rake spec
for example:
---
ActionController::UnknownAction in 'MembershipsController handling
PUT /pro
Is there any way to setup a should_receive so that it returns whatever it
was passed in from the actual code? I just want to make sure that a
specific function is called, I don't want to mess around with the
parameters it receives, or what it does inside, or what it returns. Is
that possible? Using
On 10/16/07, David Chelimsky <[EMAIL PROTECTED]> wrote:
> On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
> > Personally, if I wanted to extract this pattern, I would use a custom
> > expectation matcher.
>
> ... which would probably be implemented like this under the hood:
>
> def matches?(targ
On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
> On 10/16/07, Steve <[EMAIL PROTECTED]> wrote:
> > I've been thinking about this throughout the day, and is this a pattern
> > that should maybe be implemented in a more widespread pattern? For
> > example, check that the model makes the requisite
On 10/16/07, Steve <[EMAIL PROTECTED]> wrote:
> On Tue, 16 Oct 2007 13:43:43 -0500, David Chelimsky wrote:
>
> > On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
> >> describe Chicken do
> >> it "should make only :name and :age attr_accessible" do
> >> Chicken.should_receive(:attr_accessibl
On Tue, 16 Oct 2007 13:43:43 -0500, David Chelimsky wrote:
> On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
>> describe Chicken do
>> it "should make only :name and :age attr_accessible" do
>> Chicken.should_receive(:attr_accessible).with(:name, :age)
>> load "#{RAILS_ROOT}/app/model
Looks good.
I recently spent a lot of time looking at something similar before going
with the fixtures replacement plugin.
It gives me new_user, create_user, create_user(:first_name =>
'overriddefault' ).
Also creates records for associations where required. This is useful in
story runner, where
Thanks!
A usable stack trace now shows up in the console.
Alvin.
Ben Mabey wrote:
> This might help:
> http://www.dcmanges.com/blog/debugging-rails-integration-tests
> -Ben
>
> Alvin Schur wrote:
>
>> After trying RailsStory for a few days, I have learned:
>>
>> 1. Rails testing support does
On 10/16/07, John W. Long <[EMAIL PROTECTED]> wrote:
> This is sort of a pre-announcement for a Rails plugin my friend Adam
> Williams and I are working on. We're in the process of extracting it
> from a project we are working on so that it can be generally useful to
> the Rails community. We are c
Ahh I didnt know I had to run that again after upgrading.
I am getting a different error now..seems like its more of a Rails
issue though:
/Sites/test_appvendor/rails/railties/lib/../../activesupport/lib/active_support/dependencies.rb:266:in
`load_missing_constant': uninitialized constant Act
This might help:
http://www.dcmanges.com/blog/debugging-rails-integration-tests
-Ben
Alvin Schur wrote:
> After trying RailsStory for a few days, I have learned:
>
> 1. Rails testing support does not serve up static pages
>
> 2. RailsStory masks errors generated by the app under test
>
> 3. The ma
This is sort of a pre-announcement for a Rails plugin my friend Adam
Williams and I are working on. We're in the process of extracting it
from a project we are working on so that it can be generally useful to
the Rails community. We are calling it "Scenarios". It is a drop in
replacement for Rails
David Chelimsky wrote:
> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
>
>> After trying RailsStory for a few days, I have learned:
>>
>> 1. Rails testing support does not serve up static pages
>>
>> 2. RailsStory masks errors generated by the app under test
>>
>> 3. The masked errors are
On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> After trying RailsStory for a few days, I have learned:
>
> 1. Rails testing support does not serve up static pages
>
> 2. RailsStory masks errors generated by the app under test
>
> 3. The masked errors are available in log/test
>
> 4. I should
After trying RailsStory for a few days, I have learned:
1. Rails testing support does not serve up static pages
2. RailsStory masks errors generated by the app under test
3. The masked errors are available in log/test
4. I should read log/test more often
See http://pastie.caboo.se/107876 for
David Chelimsky wrote:
> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
>
>> Alvin Schur wrote:
>>
On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> I generated a new rails app then installed rspec and rspec_on_rails
> from
> trunk.
>
> I
On 10/16/07, Steven Garcia <[EMAIL PROTECTED]> wrote:
> I just unfroze my app and am getting the same error.
>
> Gonna reinstall a stable rspec to make sure that the trunk is really the
> issue
Try script/generate rspec first :)
___
rspec-users mailing l
On 10/16/07, Steven Garcia <[EMAIL PROTECTED]> wrote:
> @post.should_be more_specific
>
> script/spec:4:in `run': wrong number of arguments (5 for 1)
> (ArgumentError)
http://rspec.rubyforge.org/documentation/rails/install.html
script/generate rspec
You need to do that every time you update vend
I just unfroze my app and am getting the same error.
Gonna reinstall a stable rspec to make sure that the trunk is really the
issue
--
Posted via http://www.ruby-forum.com/.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/ma
@post.should_be more_specific
script/spec:4:in `run': wrong number of arguments (5 for 1)
(ArgumentError)
--
Posted via http://www.ruby-forum.com/.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users
On 10/16/07, Steven Garcia <[EMAIL PROTECTED]> wrote:
> I am getting this same error when I run autotest.
There are a few errors cited in this thread. Which one do you mean?
>
> My system specs
>
> Rails v7945
> Rspec Version 1.1.0 (in SVN)
> OS 10.4.10
___
I am getting this same error when I run autotest.
My system specs
Rails v7945
Rspec Version 1.1.0 (in SVN)
OS 10.4.10
--
Posted via http://www.ruby-forum.com/.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo
On Tue, 16 Oct 2007 14:17:48 -0500, David Chelimsky wrote:
> Do you mean the dirs inside rspec, or in the spec directory in your project?
Inside the spec dir in the project. spec/controllers, spec/models, etc...
___
rspec-users mailing list
rspec-users@
On 10/16/07, Steve <[EMAIL PROTECTED]> wrote:
> I'm just curious if there's a reason why rspec doesn't add the various
> spec dirs to $: so that "requires" can be done without specifying the full
> path name.
Do you mean the dirs inside rspec, or in the spec directory in your project?
I'm just curious if there's a reason why rspec doesn't add the various
spec dirs to $: so that "requires" can be done without specifying the full
path name.
Thanks,
Steve
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailma
On Tue, 16 Oct 2007 13:43:43 -0500, David Chelimsky wrote:
> On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
>> describe Chicken do
>> it "should make only :name and :age attr_accessible" do
>> Chicken.should_receive(:attr_accessible).with(:name, :age)
>> load "#{RAILS_ROOT}/app/model
On 10/16/07, Pat Maddox <[EMAIL PROTECTED]> wrote:
> describe Chicken do
> it "should make only :name and :age attr_accessible" do
> Chicken.should_receive(:attr_accessible).with(:name, :age)
> load "#{RAILS_ROOT}/app/models/chicken.rb"
> end
> end
>
> I first saw this technique describ
On 10/16/07, Steve <[EMAIL PROTECTED]> wrote:
> >
> > You could expect a call to attr_accessible and then load your model file.
> >
> > Or, loop through all the column names in your model, and make sure
> > that only the ones that are supposed to be accessible get set.
> >
> > Pat
>
> Expecting the
>
> You could expect a call to attr_accessible and then load your model file.
>
> Or, loop through all the column names in your model, and make sure
> that only the ones that are supposed to be accessible get set.
>
> Pat
Expecting the call is what I had originally thought of, but couldn't
figu
On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> Alvin Schur wrote:
> >
> >> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> >>
> >>> I generated a new rails app then installed rspec and rspec_on_rails
> >>> from
> >>> trunk.
> >>>
> >>> I then created a sample story:
> >>>
> >>> require
On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> Alvin Schur wrote:
> >
> >> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> >>
> >>> I generated a new rails app then installed rspec and rspec_on_rails
> >>> from
> >>> trunk.
> >>>
> >>> I then created a sample story:
> >>>
> >>> require
Alvin Schur wrote:
>
>> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
>>
>>> I generated a new rails app then installed rspec and rspec_on_rails
>>> from
>>> trunk.
>>>
>>> I then created a sample story:
>>>
>>> require File.dirname(__FILE__) + "/helper"
>>>
>>> Story "View Home Page", %{
That is what I thought (and was hoping for)
Thanks David.
> This is a bit tricky. What you're setting up here (which is true of
> message expectations in general, not must mock_model) is an
> expectation that @site will receive the message :save and that when it
> does receive it, you are instru
On 10/16/07, Chris Olsen <[EMAIL PROTECTED]> wrote:
> I am a little confused to the what happens with the following:
>
> before do
> @site = mock_model(Site, :to_param => "1")
> Site.stub!(:new).and_return(@site)
> end
>
> def post_with_successful_save
> @site.should_receive(:save
I am a little confused to the what happens with the following:
before do
@site = mock_model(Site, :to_param => "1")
Site.stub!(:new).and_return(@site)
end
def post_with_successful_save
@site.should_receive(:save).and_return(true)
post :create, :site => {}
end
I understand
> On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
>
>> I generated a new rails app then installed rspec and rspec_on_rails from
>> trunk.
>>
>> I then created a sample story:
>>
>> require File.dirname(__FILE__) + "/helper"
>>
>> Story "View Home Page", %{
>> As a user
>> I want to view
On 10/15/07, Steve <[EMAIL PROTECTED]> wrote:
> Is anyone out there writing specs to check attr_accessible fields? I had
> originally written my spec to check for allowing the desired fields, and
> then none of the other regular db fields. Unfortunately this isn't
> satisfactory, because attr_prote
On 10/16/07, Dylan Markow <[EMAIL PROTECTED]> wrote:
> I have a controller that gets a list of employees (which has an "include =>
> [:salaries, :incentives, :billablegoals, :reviews]"). I then need it to
> iterate through each employee and determine their current active goal based
> on the "effect
On Tue, 16 Oct 2007 10:39:32 +0200, Wincent Colaiuta wrote:
> Yes, I spec this kind of thing.
>
>describe User, 'accessible attributes' do
> it 'should allow mass-assignment to the login name' do
>lambda { new_user.update_attributes(:login_name =>
> String.random) }.should_not
Okay I'm retarded. I added a helper method "def current_goal" to my Employee
model and can test it there, so I don't even need the @employees.each...
line.
Dylan Markow wrote:
>
> I have a controller that gets a list of employees (which has an "include
> =>
> [:salaries, :incentives, :billableg
On 10/16/07, Dylan Markow <[EMAIL PROTECTED]> wrote:
> I have a controller that gets a list of employees (which has an "include =>
> [:salaries, :incentives, :billablegoals, :reviews]"). I then need it to
> iterate through each employee and determine their current active goal based
> on the "effect
On 10/16/07, Alvin Schur <[EMAIL PROTECTED]> wrote:
> I generated a new rails app then installed rspec and rspec_on_rails from
> trunk.
>
> I then created a sample story:
>
> require File.dirname(__FILE__) + "/helper"
>
> Story "View Home Page", %{
> As a user
> I want to view my home page
>
I have a controller that gets a list of employees (which has an "include =>
[:salaries, :incentives, :billablegoals, :reviews]"). I then need it to
iterate through each employee and determine their current active goal based
on the "effective date."
After playing around with it a bunch, I got the f
I generated a new rails app then installed rspec and rspec_on_rails from
trunk.
I then created a sample story:
require File.dirname(__FILE__) + "/helper"
Story "View Home Page", %{
As a user
I want to view my home page
So that I can get a birds eye view of the system
}, :type => RailsStor
This isn't in production, it's not even fully baked. It's just
something I hacked away at over a couple of weekends. I can show you
where I wanted to get to (off the top of my head) :
http://pastie.caboo.se/107693
( adapted from
http://evang.eli.st/blog/2007/9/1/user-stories-with-rspec-s-story-ru
http://tinyurl.com/2bolrs
I'm working on a series of screencasts on RSpec and BDD. This first
iteration is on the real basics.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users
On 10/16/07, Josh Chisholm <[EMAIL PROTECTED]> wrote:
> Hi all. I'm with David in that plain-text specs are my holy grail. I
> have actually been experimenting with this idea since I first saw the
> story runner. My interpreter (spike!) would execute "specs" against
> "proofs", but I tried to put a
El 16/10/2007, a las 6:50, Steve <[EMAIL PROTECTED]> escribió:
> Is anyone out there writing specs to check attr_accessible fields?
> I had
> originally written my spec to check for allowing the desired
> fields, and
> then none of the other regular db fields. Unfortunately this isn't
> satisf
Hi all. I'm with David in that plain-text specs are my holy grail. I
have actually been experimenting with this idea since I first saw the
story runner. My interpreter (spike!) would execute "specs" against
"proofs", but I tried to put a bit more into the grammar.
Specifically, the interpreter woul
Nevermind, I newbed the named route. It's obviously too late, and I should
be in bed.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users
55 matches
Mail list logo