similar to: How do I mock params?

Displaying 20 results from an estimated 2000 matches similar to: "How do I mock params?"

2007 Dec 13
4
Attachment_fu problems on updates
On the creation of a member the member''s picture uploads as it should. However, when updating the member, while selecting a new picture, an error is thrown: can''t convert nil into String RAILS_ROOT: /Users/chris/Documents/Projects/Rails/CommunityCMS/trunk Application Trace | Framework Trace | Full Trace
2005 Jan 10
2
rubytorrent
hello, we are interested in using rubytorrent as a project in a hackfest we''re organizing, and I would like to know if you have any idea of stuff that needs to be done, or something like it. Thanks, --lf
2007 Dec 05
9
Does mock_model''s :null_object option work?
Please understand in the following that I am making relatively minor changes to legacy (non-TDD/BDD) code in Substruct and don''t have the time to refactor nicely right now. I''m just trying to get past the untested/un-speced cruft quickly to write the spec for my new code, so I''m looking for expediency over prettiness. I''m specifying before( :each ) do
2009 Jun 19
3
Planning of next challenges for Firefox
Fellow open video enthusiasts, Chris Blizzard just suggested that with all the Xiph developers attending the OpenVideoConference, we should all get together and discuss the next things to attack for Ogg Theora/Vorbis in Firefox. I think that's a great idea. Assuming that everyone stays for the hackfest on Sunday, we picked 10am on Sunday for a thorough discussion and planning session (1-2
2007 Oct 16
2
Does a mock model have to satisfy contraints
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 that the "@site.should_receive(:save)..." places a check to whether the
2007 May 30
18
autotest and rspec_on_rails not happy
Hi, I''ve been using the rspec and rspec_on_rails plugins quite happily on my Rails project for a while now. Today I noticed the autotest support in RSpec-1.0.3 and decided to give that a spin. Oh tragedy! $ autotest loading autotest/rails_rspec ./vendor/plugins/rspec_on_rails/lib/autotest/rails_rspec.rb:33:in `initialize'': undefined method `singularize''
2003 Jan 02
2
--copy-unsafe-links, links preserved in source tree or local directory?
Hi, I'm a bit confused about what the '--copy-unsafe-links' option considers the 'source tree'. In the man page it says that for links pointing outside the 'source tree' the file will be copied, but when I try this, for all links pointing outside of the local directory the files are copied even though the links point to files that are in the directory tree that is
2006 Mar 01
2
o''reilly''s arrogance
although basically hopeful of the company''s ''rough cuts'' venture, i am insulted by the fact that o''reilly''s safari service offers important material to its regular subscribers only if they pay extra for it. o''reilly''s material on ajax is a good example: all of the introductory coverage is available only as pricey ''rough
2009 May 03
12
DNAT Question
Hi list, I have a shorewall installed on 2 interfaces which also has multiple static public IP. Let''s say I have 1.2.3.4 and 1.2.3.5. I have assigned nat with: 1.2.3.4 eth0 11.22.33.4 no no But then I have a situation where I need 11.22.33.44 to connect to a host in the net zone and appears also to be 1.2.3.5 not only 1.2.3.4. How to do it? TIA Willy
2006 Jan 23
6
Ruby at O''Reilly Rough Cuts
Not sure if this is old news or not, but it would appear that both the Ruby Cookbook and a Rails book are now available for purchase at O''Reilly Rough Cuts (something akin to PragProg''s beta book program): http://rubyurl.com/nHz http://my.safaribooksonline.com/?mode=roughcuts&srchtext=ROUGHCUTS I haven''t tried them yet, but it definitely seems worth checking out.
2006 Jun 13
21
RJS Templates for Rails
I''m happy to announce the availability of RJS Templates for Rails published by O''Reilly. The book covers all aspects and features of RJS that are included in Rails 1.1. It also walks through a few examples, debugging with FireBug, and finishes off with some reference material. The book is 56 pages and is available in PDF format. I''m really happy with how the book has
2008 Nov 01
5
Issues after removal of rpsec plugins and gem install
autotest will no longer run my tests after I installed the rpsec gem and removed the plugins. I did install the rspec-rails gem as well. Is anyone else having this issue? -- Posted via http://www.ruby-forum.com/.
2000 Oct 23
3
behaviour of plot(...,type="l")
plot(rnorm(100000),type="l") plots only about 7e4 lines while the same without type="l" works fine. Is this a feature or a bug or is this configurable? R : Copyright 2000, The R Development Core Team Version 1.1.1 (August 15, 2000) SunOS 5.5.1 Generic_103640-29 sun4u sparc SUNW,Ultra-1 Thanks Adrian -- Adrian Trapletti, Olsen & Associates Ltd., See- feldstrasse
2007 Mar 30
1
Fwd: New Short Cut: Ferret
Congrats David!!! Very cool. Erik Begin forwarded message: > From: "O''Reilly Media" <ormadmin at oreilly.com> > Date: March 30, 2007 6:22:36 PM EDT > To: erik at ehatchersolutions.com > Subject: New Short Cut: Ferret > > ***New from the O''Reilly Store*** > > Ferret > http://www.oreilly.com/catalog/9780596527853 > > By David
2011 Feb 08
2
Ken Olsen od DEC, 1927-2011
A lot of us wouldn't be here without him. DEC made good, really reliable hardware. mark <http://www.networkworld.com/news/2011/020711-kenneth-olsen-dec-obit.html>
2004 Mar 27
2
gregmisc: install trouble
Hello all, I'm having trouble installing the package 'gregmisc'. I've run the command: > R CMD INSTALL -l /usr/lib/R/library /tmp/gregmisc_0.9.0.tar.gz And I can see it shows up on the list of available packeage when I issue > library() But when I do >library(gregmisc) I get: Error in parse(file, n, text, prompt) : syntax error on line 3105 All the other packages
2015 Sep 16
4
Realtime Voicemail MWI
Greetings All, Regarding this archived post. http://lists.digium.com/pipermail/asterisk-users/2014-November/285169.html Did anyone ever find an solution to this? I've got a new box running 13.3.0 with the exact same issue. For those that don't read the link. I've got SIP Peers in realtime. All with a mailbox set. 98% of the time, These are loaded into asterisk without
2009 Jan 05
1
login fails when username has apostrophe
Hi I've added the apostrophe character to auth_username_chars however authentication still fails. I'm using LDAP with the following details: dovecot version 1.1.7 openldap client library 2.4.11 With auth_verbose = yes and auth_debug = yes set I see the following in the logs. Note the initial escaped apostrophe and the subsequent escaped escape in the filter! ----- start log ----- Jan
2007 Nov 21
6
route_for and nested resources
I can''t figure out how to make the updates to allow for the route_form method to return a url that matches the expected. Here is a sample route_for(:controller => :task, :action => :new).should == "/task/new" If a task has to be created for a user, how exactly do I do this. The following doesn''t work: route_for(:controller => :task, :action => :new,
2009 Aug 23
5
Upgrading to 2.3 from 2.1
Can be done in a one step process or do I have to upgrade to 2.2 then 2.3? Thanks for the help. -- Posted via http://www.ruby-forum.com/.