Displaying 20 results from an estimated 600 matches similar to: "Rails Day 2006 -- 24 hour programming contest on July 17th"
2007 Apr 17
5
How to change the default encoding for dynamic pages
Hello,
I''m trying to write a rails application serves by mongrel and using
accentuated characters in the .rhtml page. But Mongrel replace them by ''?'' .
It works fine for static pages by defining the charset to iso-8859-1 in the
mongrel_mime.yml
But how to change the default encoding (seems to be UTF-8) for the dynamic
pages ?
thanks for your help.
-------------- next
2007 Jan 12
3
Content-Length: 0
While trying to debug a goofy XML loading issue in IE, I''ve found
that Mongrel (latest) returns Content-Type: 0 with every request on a
particular (CentOS 4) server, yet not on my local (OS X) box. These
both access identical Rails apps. This seems like a clue, but thought
I''d ask here if for some reason this is expected behavior. Both
running Ruby 1.8.4. Both return
2007 Feb 27
3
mongrel_cluster and Monit
On one of my development servers mongrel dies when idle for any length
of time. Since I''ve not been able to solve that problem I thought I''d
route around it by using monit to kick things when necessary.
My monitrc contains the following...
--------------------------------------------------------------------------------
check process mongrel_8310 with pidfile
2006 Oct 06
8
Expecting calls with two different parameters
Hello,
I''ve just started using Mocha in the tests for my Rails app, and I''ve
run across an issue with mocking a method that should be called with
different parameters.
How would I setup a mock that expects that a method will be called
once with no paramaters, and a second time with a parameter? I''d be
tempted to shortcut and just do something like
2006 Oct 17
4
Mocking the rendering of a Rails template
Hello all,
I''m having difficulty setting up mocks such that I can verify that
Rails was going to render the right template file (for example
new.rhtml) and stop Rails from performing the actual rendering.
After peeking at Rails'' internals, I tried two techniques as illustrated here:
http://pastie.caboo.se/18197
Neither worked.
I think the first one failed because Rails
2006 Oct 08
9
Organizing tests and mocha expectations
I''m simultaneously getting into using Mocha and RSpec-style tests
(courtesy of the simply_bdd plugin) and I''m struggling with some
issues while trying to organize my specs/test. Here''s a code example
illustrating the problem:
context "update cliient invalid data" do
include ClientsControllerSpecHelper
specify "should render edit form" do
2006 Feb 22
3
is there really a restart task in switchtower? How do you invoke it?
I just created a new rails project "test".
I then did "switchtower --apply-to ~/user/test test"
I then moved into test and tried "rake restart" and got:
kfelkins@lurch:~/user/test$ rake restart
(in /home/kfelkins/user/test)
rake aborted!
Don''t know how to build task ''restart''
I see restart in deploy. Can restart be invoked from the
2007 Jan 09
6
spec not running in TextMate
I tried running a spec with command-r in TextMate and got:
/Library/Application Support/TextMate/Bundles/RSpec.tmbundle/Support/
lib/spec_mate.rb:1:in `require'': No such file to load -- rubygems
(LoadError) from /Library/Application Support/TextMate/Bundles/
RSpec.tmbundle/Support/lib/spec_mate.rb:1 from /tmp/
temp_textmate.GplhPr:3:in `require'' from
2007 Mar 10
5
Mongrel Hangs After Idle Period
I had posted a thread couple of weeks ago whereby mongrel just mysteriously
stops interacting with my application after an idle period...usually less
than 8 hours.
http://rubyforge.org/pipermail/mongrel-users/2007-February/002908.html
I had hoped this would go away after a few upgrades but to know avail.
Interestingly, the process does not die...it still accepts HTTP requests but
does not
2007 Mar 19
24
alias method spec?
I am completely baffled by this one - My guess is that there is no
pure ruby way to do this - but how could I set up a spec to test that
one method is an alias of another?
Thanks for any help,
Scott
2007 Feb 17
4
RSpec usage
Hey all,
Trying to get feel for RSpec usage so I''m taking a straw poll...
What''s the largest project you''ve used RSpec on in terms of app LOC
app and spec LOC? Also, how long have you been using RSpec in
"production" code?
-Bryan
2006 Mar 25
4
Can''t quite get Rails working on Mac, help please :).
I''ve followed the install the install guide on
http://hivelogic.com/articles/2005/12/01/ruby_rails_lighttpd_mysql_tiger
and it seemed to work. And I''ve been following the Instant Gratifiction
guide in Chapter four in Agile Web Development with Rails book. I''m in
terminal and I type -
cd work (everything works fine) then
rails demo (everything seems to work) then
cd
2007 Mar 25
3
New Style: describe-it instead of context-specify
Hello,
in the tunk, i found a new style for spec:
describe Foo do
it "should do bar" do
...
end
end
instead of
context "Foo"
context "should do bar"
...
end
end
The Rails-Textmate-bundle in trunk use only the new "describe-it"
style,
What are the reasons for the new style ?
Shall i use the new style from now on ?
Hussein
2008 May 14
4
Reuse steps like a method call
If I have a step matcher defined as so:
Given "a user named $username" do |username|
....
end
Is there a way to call it from another step? For example:
Given "a user named $username with a blog post |username|
given_a_user_named(username) # calls existing step code
# create a blog post
end
Cheers,
--
Bryan Helmkamp
http://brynary.com -- My blog
2002 Aug 07
3
Reading characters using read.table()
Hello,
I need to read a vector containing names of different variables from a
text file (a unique column). Among them one is called "T". When I use
the function read.table with default arguments and when I call the
element of the data frame corresponding to name of this variable it
returns me the logical value "TRUE" whereas I was expected it to return
the character
2007 Nov 29
5
Webrat 0.1.0 released - Ruby Acceptance Testing for Web applications
Hey guys,
We developed this plugin while writing my first real set of RSpec
stories. It''s still missing a lot of functionality, but it''s useful to
us as is, so I''m shipping 0.1.0. (Patches welcome. :) )
Code is available at: http://svn.eastmedia.net/public/plugins/webrat/
What do you think?
-Bryan
Here''s the README:
2002 Aug 01
2
Building a function
Hello,
Is it possible to build a function, a posteriori, by getting the names
of the arguments and the formula in a list or a vector ? When I use the
function as.function(), I don't know how to define explicitly the names
of my variables as formal arguments.
Thanks
_______________________________________
Florent BATY
CNRS UMR 5558
Dynamique des Populations Bact?riennes
Facult? de
2008 May 03
9
Any news on the rSpec books?
I admit it, when it comes to rSpec, I''m lazy. I''ve made a few feeble
attempts to use it, but for once I''m waiting for a book-length
treatment. At least two books were announced, I think. Can anyone in
the know please report on their progress?
Thanks
Michael
--
Michael Schuerig
mailto:michael at schuerig.de
http://www.schuerig.de/michael/
2005 Nov 11
1
Snow parLapply
Dear R-user,
I am trying to use the function 'parLapply' from the 'snow' package
which is supposed to work the same wys as 'lapply' but for a
parallelized cluster of computers. The function I am trying to call in
parallel is 'dudi.pca' (from the 'ade4' package) which performs
principal component analyses. When I call this function on a list of
2006 Jun 03
0
Any RoR experts without an idea for Rubyday2006?
I''m a 50 year old mainframe programmer from the Netherlands that has
just started his RoR journey with a GREAT idea for a project to enter
for Railsday2006.
To quote Geoffrey Grosenbach in an email when I approached him to help
me realize the project; ?That''s an interesting idea.? & ?It could be a
great project for RailsDay?
Sorry for name dropping Geoffry, but I need