My team is working on a plugin and we want to use RSpec internally for the
plugin's tests.
(a) What are some different ways to go about this? Should we rely on the
RSpec gem? Should we expect that the "host" Rails application has installed
the RSpec plugins? Are there other options?
(b) Which
Thanks!
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users
I've seen reference to an 'add' method, as in Model.add. When and why would
I want to use it? Is it related to Model.collection.build?
Thanks,
David
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-user
I'm currently try to push my limits a little bit with some of my unit
testing -- trying to avoid saving ActiveRecord objects to the database and
take advantage of mock/stub objects.
How far should I expect to get in this direction? From what I can tell,
ActiveRecord seems to fight me when it come
I wish I was more specific, indeed. :)
While scouring the Web for examples of mocking ActiveRecord associations
(see other thread), I saw the add method -- but couldn't figure out what it
did. That made me wonder if it was perhaps some special construct in RSpec
(perhaps for helping with associat
In case it helps those who want to make it a little easier to try both at
the same time (i.e. a bridge), ReinH has got a script that helps use
autotest growl with both Test::Unit and RSpec:
http://reinh.com/2007/9/12/the-autotest-rosetta-stone
___
rspec-u
>
> "But otherwise, what exactly are you testing?"
>
That's a great point. I don't want to be specing Rails if it is not easily
separable for testing already. In theory, I would like to have true unit
tests for my models. However, in practice, some of my models are coupled to
some degree.
Gener
I have a page that hides elements using CSS display: none.
I don't expect RSpec to test any changes made by Javascript; I just want to
test how the page loads initially: what is visible and what is not.
Can I test this in RSpec? Or do I need to use something like Selenium?
__
Perfect. That's really nifty. I'm also reading the comments in
selector_assertions.rb in actionpack.
On 9/25/07, David Chelimsky <[EMAIL PROTECTED]> wrote:
>
> On 9/25/07, David James <[EMAIL PROTECTED]> wrote:
> > I have a page that hides elements using
describe "should_not == vs. should !="
it do
5.should_not == 6
end # passes
it do
5.should != 6
end # fails
end
# I'm running the rspec 1.1.2 gem with the corresponding Textmate bundle
# The second failure surprises me.
# Is != not supported?
# I'd like to hear what you all think.
-1*
I upgraded a Rails project from rspec 0.9 to 1.1.2 -- and this change caused
me some pain. Luckily, I figured it out and confirmed it here on the list
before things got too bad. :)
* That said, I have to admit that I'm not super-pleased about my helper
methods that start with should_ -- they p
11 matches
Mail list logo