gende geschreven:
> On Jul 13, 2010, at 7:25 AM, Ivo Dancet wrote:
>
>> Hi
>>
>> I'm upgrading an application to rspec2/rails3. A certain suite of tests,
>> that generates a pdf document, uses a before(:all) filter to set the
>> environment using mocks an
Hi
I'm upgrading an application to rspec2/rails3. A certain suite of tests, that
generates a pdf document, uses a before(:all) filter to set the environment
using mocks and stubs. Then the pdf gets generated and after that all the tests
run on that same pdf document. In rspec2 it seems like I c
n...
http://google-opensource.blogspot.com/2009/05/introducing-webdriver.html
It won't work right out of the box as it uses selenium in the end. It
should however be quite easy to rewrite the two commands that access
selenium directly if WebDriver makes it possible to execute js in the
dialog div").text.should have_text(/some_text/)
- jquery("#dialog").find(".warning")
- jquery("#dialog").html.should have_tag("button", "Ok")
- jquery("#dialog").should be_visible
- jquery("#dialog") # page m
Done:
http://rspec.lighthouseapp.com/projects/5645-rspec/tickets/641-form-tag-helpers-in-helpers
Regards
-c
Op 30-dec-08, om 16:41 heeft David Chelimsky het volgende geschreven:
On Tue, Dec 30, 2008 at 9:14 AM, Ivo Dancet > wrote:
Hi
I bumped into a problem and tracked it down to t
Hi
I bumped into a problem and tracked it down to this:
Form tag helpers in helpers do not seem to be testable. The helper
does actually work like it should if used in a view.
Example:
This helper:
#
def form_builder
form_tag "foo" do
text_field_tag("bar")
end
end
And
Hi
The 'loadavg' method is an instance method of 'whm', so the test
should be:
@whm = mock_model(Whm::Client)
Whm::Client.stub!(:new).and_return(@whm) # make the new method to
return a mock object
@whm.stub!(:loadavg).and_return(3) # 3 is the dummy loadavg, maybe you
can change it in someth
Hi all
Tonight I wanted to test out selenium in a story to test some ajax
stuff on a page.
After struggling for an hour or two with disappearing database objects
I found the solution in a blog post by Kerry Buckley.
with the comment included it reads:
# Don't add an ActiveRecordSafetyListen
Op 19-mrt-08, om 16:33 heeft Dave het volgende geschreven:
> Hi there,
>
> I'm still trying to wrap my head around when to use a stub and a mock.
> If I understand this right, I should be using a 'mock' when imitating
> an object, but not its behavior. I should be using a stub when I want
> to imi
step you set your host, user name and password and you
create that user.
In the when steps you make the login request and then you can start
doing the stuff you really want to test here as you'll have the
session you want at that moment.
Regards
Ivo Dancet
Op 6-mrt-08, om 16:12
I think you can also use:
post "/authentication/login",
{ :login => user_email,
:password => password },
:host => "company.example.com"
Op 5-mrt-08, om 23:30 heeft Bastien het volgende geschreven:
> I've just begin using rspec stories, and i m encountering some
> problems. In my applica
Op 16-feb-08, om 19:26 heeft Steve het volgende geschreven:
> On Sat, 16 Feb 2008 13:06:00 -0500, David Chelimsky wrote:
>>
>> The rspec/rails plugin works because there are generators which
>> create
>> the files for you, not because of any auto-loading facility. The
>> generated files have re
Op 16-feb-08, om 15:13 heeft David Chelimsky het volgende geschreven:
> On Feb 16, 2008 9:10 AM, Ivo Dancet <[EMAIL PROTECTED]> wrote:
>> That was very quick, thanks!
>>
>> No, I was not (and it works when I require the file), I thought rspec
>> would have some
On Feb 16, 2008 8:51 AM, Ivo Dancet <[EMAIL PROTECTED]> wrote:
>> Hi
>>
>> I can't seem to get rspec and autotest to work in a small test
>> project. The spec command doesn't load the implementation file. I
>> found some info about non-rails projec
Hi
I can't seem to get rspec and autotest to work in a small test
project. The spec command doesn't load the implementation file. I
found some info about non-rails projects with rspec, but these did not
solve my problem.
I have the following files:
project_map/
lib/todoist.rb
o2"})
And it did get it with ({:name => "foo"}), but only the first time...
Thanks!
Ivo
Op 13-jan-08, om 14:00 heeft David Chelimsky het volgende geschreven:
> On Jan 13, 2008 6:56 AM, Ivo Dancet <[EMAIL PROTECTED]> wrote:
>> Hi all, I have a method calling Klass.
Hi all, I have a method calling Klass.create! two times with different
arguments (this happens in a class reponsable for reading in a csv file)
I want to test those like this:
in one test: Klass.should_receive(:create!).with(:name => "foo").once
in another: Klass.should_receive(:create!).with(:
ot;,
"pass")
end
Then "I'm logged in" do
response.should be_success
end
end
What happens is that the second scenario's response is also returning
401 and if I switch the order of the two scenar
Any recommendations on this?
Regards
Ivo Dancet
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users
19 matches
Mail list logo