similar to: Helper methods starting with should_ get picked up as examples?

Displaying 20 results from an estimated 100 matches similar to: "Helper methods starting with should_ get picked up as examples?"

2007 Apr 09
10
changes in 0.8 and greater - should_
Has the should_... syntax changed? I''m getting errors when running the following: should_render(:index) should_be_valid should_not_be_valid should_respond_to should_be should_render I thought the syntax changed to something like the following: obj.should render(:index) but this doesn''t seem to work. Scott
2007 Nov 18
8
helper methods starting with should
Hi all, As an experiment in playing nice with others, we''ve added the ability in rspec''s trunk to do this: class ThingExamples < Spec::ExampleGroup def should_do_stuff ... end end This is how rspec 0.1 worked, and for people already comfortable with the classes/methods approach of Test::Unit, it is a more comfortable entry point to rspec. For others, however, it
2007 Jul 26
3
Canonical way to generate RSpec HTML report in Rails app
Hi! I was just wondering how you typically generate a spec HTML report in a Rails app. Currently I''m doing something like this: spec spec -f h:spec/spec_report.html But that seems sort of clumsy and I would have thought that there was a rake task for it. Have I overlooked something? Thanks! Peter ---------------------------- Peter Marklund Garvar Lundins Gr?nd 7 11220 Stockholm
2006 Oct 24
5
Radrails and RSpec
Hi all, Does anyone know how to get radrails to use RSpec specs instead of tests? Cheers --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to
2008 Jan 10
21
Shoulda
Hey, we''re currently using shoulda (http://dev.thoughtbot.com/ shoulda/) on a project and I saw some things that would be really nice to see in rspec, namely the should_ methods, and especially the should_be_restful method. Do these go against the rspec goals at all? Or could an ambitious programmer go to town implementing these for rspec_on_rails? Nathan Sutton fowlduck at
2007 May 30
2
should_eql etc?
Hi, I''m trying the specs for restful_authentication I found here http://jonathan.tron.name/articles/2007/01/02/rspec-on-rails-restful- authentication It seems to use custom .should methods: should_eql, should_be_an_instance_of, should_redirect_to, should_be_success, should_not_be_nil, should_be_nil, should_not_be_nil, should_be_empty, should_be_success, should_not_change, and
2010 Aug 11
6
rspec2 not working with shoulda
I am using rails edge. I am using gem "rspec-rails", "= 2.0.0.beta. 19" . I have following code at spec/models/user_spec.rb require ''spec_helper'' describe User do it { should validate_presence_of(:email) } it { should validate_presence_of(:name) } end Here is my gemfile group :development, :test do gem ''factory_girl_rails'',
2007 Aug 31
3
Setting use_transactional_fixtures=false for a single spec - a bad idea?
Hi! I would really like to find a way to allow me to write RSpec specifications for code that use database transactions. I know I can set config.use_transactional_fixtures = false in my spec_helper.rb. That works, and that''s great, but it will (I think) slow down my specs quite a bit. I would like to turn off transactional fixtures for just a single spec (describe), or even
2007 Sep 21
11
given_it
Hello, Just decided to check whether I am doing something that makes sense or not. I was thinking about how cool would it be to re-use examples (just like we reuse story scenarios with GivenScenario). I was not sure if this possibility already exists in rspec (and, honestly, was lazy to check), so I have created this helper: def given_it(name) example_definition =
2010 Dec 23
6
Difference between rake test:units and individually running ruby -I test test/unit/something_test.rb ?
Here''s my issue: running ruby -I test test/unit/something_test.rb for each of my unit tests works perfectly. However, running rake test:units brings errors in all of them - some object becomes nil for some reason. Why might this be happening? Specifics: the object that is successfully not nil when I run the unit tests one-by-one but becomes nil when I do rake test:units is defined like
2007 Aug 31
48
Deprecating the mocking framework?
I saw in one of Dave C.''s comments to a ticket that "our current plan is to deprecate the mocking framework." I hadn''t heard anything about that, but then again I haven''t paid super close attention to the list. Are we planning on dumping the mock framework in favor of using Mocha (or any other framework one might want to plug in?). Pat
2010 Mar 05
6
About autosigning and the FAQ entry
Hello! The FAQ contains an entry about autosigning: http://reductivelabs.com/trac/puppet/wiki/FrequentlyAskedQuestions#why-shouldn-t-i-use-autosign-for-all-my-clients It says: > The certificate itself is stored, so two nodes could not connect with the same CN I tried this (using 0.25.4), and actually, that doesn''t seem to be correct. I was able to run puppetd on two different
2006 Nov 30
41
TDD killing my joy of Rails
I''ve been working through the book ''Beginning Ruby on Rails E-Commerce'' which is very heavy on Test Driven Development. As in, you have to write tests for scaffolding methods and validations and crap like that. And then they fail. And you KNOW its the test not the method. So you spend 2x the time writing a test that has to be adapted when requirements change. You
2012 Feb 16
4
Could not set present on ensure: Read-only file system
Hi, I try install python-psycopg2 with other packages, when run apt-get -y update returns the errors: err: /Stage[main]/Etc/Package[build-essential]/ensure: change from purged to present failed: Could not set ''present on ensure: Read-only file system - /tmp/puppet20120216-1063-18q7lsz-0 at /tmp/vagrant-puppet/manifests/vagrant.pp:15 err:
2007 Aug 24
26
testing behaviour or testing code?
hypothetical question for all you BDD experts: I want to make sure that a :list action always returns widgets in alphabetical order. There''s at least 2 ways of doing this: it "should fetch items in alphabetical order" do Widget.should_receive(:find).with(:order => "name ASC") get :list end it "should fetch items in alphabetical order" do [:red,
2006 Mar 31
3
ID fields not getting picked up
For example I have table Questions. With fields id, text, and test_id. test_id is not being displayed in my view. I am hoping this means Rails has picked up that it is an id for another model. If so, then how do I utilize that? If not, then do I need to avoid ''id'' in any field names other than the main id field? Thanks! -- Posted via http://www.ruby-forum.com/.
2007 Jun 12
0
On multiple dial phones continue ringing after picked up
Hello, I'm using a dial command to make several phones ring. I use this format : Dial(SIP/4029&SIP/4030,15,tTr) As soon as one of the phone is picked up, all the others should just stop rining. But the fact is that they continue to ring for several seconds (4-5s), and this is quite annoying as all phones are in the same room. Phones are Siemens Gigaset C450IP and Linksys SPA921. Do you
2003 Sep 04
1
remotely picked-up extension keeps ringing
Hello, As of today's cvs * snapshot I am able to pickup a ringing (sip) cisco 7960 with *8 but the extension then keeps ringing indefinitely, even though I picked up the call. Is this a known issue? Thanks, -- There are no Debian developers in any part of Hell, because the good karma incurred by being one takes you straight to the pearly gates. Of course, the frequent flame wars you put
2004 Jul 28
1
ParkAndAnnounce Doesn't Release when Call is Picked-up
Hi All, When a call comes into my FXO port (Zap/1), it goes into the ParkAndAnnounce app and gets parked. This is OK. Then the app announces the file I selected through the (Console/dsp). This is OK. If I go to another extension FXS (Zap/2) and dial the parked call, then I get connected OK (Zap/2 & Zap/1). The problem is the Announcement through the (Console/dsp) doesn't stop, it
2005 May 12
0
Incoming calls picked-up then simply hanged-up
I had the same issue at one stage although it was with call files - check what your WaitTime is. Mine was set to 5 which means 5ms so only half a ring and then it would hang-up. -----Original Message----- From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of fhunter Sent: Thursday, May 12, 2005 1:58 PM To: 'Asterisk Users Mailing List -