Displaying 20 results from an estimated 1000 matches similar to: "Feature request... I think..."
2007 Dec 21
5
Mocha and rails 2.0.2?
Folks-
With Rails 2.0.2, I''m seeing mocha failures where they did not fail
with Rails 2.0.1
test_set_to_process_fail_in_transaction(FileRecordTest):
NoMethodError: undefined method `ord'' for 63:Fixnum
/home/wolpert/svn/rubylms/vendor/plugins/mocha/lib/mocha/class_method.rb:45:in
`hidden_method''
2008 Jan 28
9
Nested matchers
We''re encountering a failure with Mocha 0.5.6.
We had this expectation:
game_version.expects(:attributes=).with(:game_file =>
kind_of(GameFile), :game_id => @game.id)
This expectation was passing with 0.5.5, but fails with 0.5.6.
I added this test to parameter_matcher_acceptance_test.rb, which
passes in 0.5.5 and fails in 0.5.6
def test_should_match_nested_parameters
2008 Jun 12
2
Anyone using trunk?
Has anybody been using Mocha trunk over the last month or two?
I''ve done quite a bit of internal refactoring and wondered whether
anyone had any problems.
There are also a bunch of new features e.g. states, sequences, extra
parameter matchers & configurable warnings, but these are not
documented in the on-line rdoc.
I wondered if anyone has been looking at the rdoc in trunk and
2007 Mar 06
15
mocking missing methods
Hi folks.
So I''m using mocha on a ruby project, and I really like it. One thing
I''ve noticed is that it can be a bit "surprising" when I''m mocking
methods that don''t exist on an object, and I think there''s an easyish fix.
At the moment, you use sheep = mock() to create a mock sheep. What I''d
like to do is something like sheep =
2006 Dec 04
7
I need help to connect Postgres and Ruby on Rails Please.
Hello to everyone, I have a problem that is giving me a headache, and
trying to do a project in Ruby on Rails and I need to connect with a
Data Base that is en Postgres, the truth is that I didn’t think that it
was so hard to connect a DB with postgres because I was working with
Msyql and everything was easy. This are the thinks that I have install
in my computer.
1. Debian GNU/Linux, kernel
2007 Apr 12
15
Preview of Latest Mocha Changes
I''ve finally managed to find some time to do some serious work on
Mocha. There are some code snippets on my blog
(http://blog.floehopper.org/articles/2007/04/12/preview-of-latest-mocha-changes)
showing the new functionality available in trunk (revision 128). I
don''t don''t know how many people out there are using trunk, but it
would be great to get some feedback on these
2001 Nov 06
1
rsync for realtime filesystem replication.
Apologies in advance for a kind of long question:
I've written an application called changedfiles
(http://www.bangstate.com/software.html#changedfiles), which consists of two
parts: a linux kernel module that reports all file operations to a device
special, and a userspace daemon which can take arbitray shell action on files
matching regexp rules specified in a config file.
E.G.,
2004 Aug 06
1
Icecast deadlock with 1.3.12 (fixed)
This is in CVS, FWIW (that is, not much since the odds of 1.3.13 being
released are epsilon close to nil).
On Wednesday, 02 July 2003 at 11:38, Ned Wolpert wrote:
> Folks,
> I email abit ago about using 1.3.12 in my environment, and fixing a
> dead-lock problem. Since 1.3.12 is 'obsolete', not supported, and GPL
> I'm provided a patch to the mailing list of my
2004 Aug 06
5
Icecast deadlock with 1.3.12 (fixed)
Folks-
First, let me submit a disclaimer... I know 1.3.12 is unsupported.
However, since icecast2 isn't officially released, I'm abit SOL anyways,
so I'm currently trying to debug it and will release a patch when I'm
done. (Which I'm doing since the code is GPL and I want to
contribute... if no one cares, let me know and I'll stop updating the
list with what i find)
2008 Apr 13
1
Incorrect @INC: Rcmd SHLIB error under Windows (2.6.2, 44383) (PR#11161)
Hi, R team.
I'm trying to build a dll from a c program to be invoked within R using
the .C() functionality.
Everything works like a charm on my Linux (Centos 5) (also 2.6.2) machines---
but under windows (Vista Ultimate) upon running (in either the windows 'Cmd'
command window or a Bash window) the command
Rcmd SHLIB myfun.c
I receive the error:
Can't locate R/Utils.pm in
2006 Nov 10
3
Stubbing Time.now in trunk
I''m a big fan of stubbing Time.now so it returns a known value. I used
to be able to use stubba and say:
@time_now = Time.parse("Jan 1 2001")
Time.stubs(:now).returns(lambda{@time_now})
However, something in trunk broke that. Fine, rspec''s got its own
stubbing lib now, so I tried switching to that:
@time_now = Time.parse("Jan 1 2001")
2007 Feb 21
4
CentOS 4.4 on Dell PE 6400 - not rebooting ...
Hi All,
This is my first post ... I *HAD* been trying to get RHEL AS 4 onto
this Dell PE 6400/700, but it just wouldn't go without some weird
tweaking.
I am VERY happy to say that CentOS 4.4 installed without a hitch!
NICELY done folks!
The only real issue for me is that the machine fails to reboot or
shutdown correctly.
It requires physical interaction with the power switch,
2006 May 17
9
Render No Layout?
Hi guys,
Am having a problem.
I have this def in my index controller that works like this:
def do_something
$a = variable1
$b = variable2
$c = variable3
$d = ""<script language=\"Javascript\"> \n new Insertion.Bottom(''#{$c}'',
''#{$a} - #{$b}''); \n </script>"
$trigger = "1"
render(:partial =>
2010 May 04
3
Idiomatic looping over list name, value pairs in R
Considering the python code:
for k, v in d.items(): do_something(k); do_something_else(v)
I have the following for R:
for (i in c(1:length(d))) { do_something(names(d[i]));
do_something_else(d[[i]]) }
This does not seem seems idiomatic. What is the best way of doing the
same with R?
Thanks.
Luis
2015 Jul 16
3
[LLVMdev] why LoopUnswitch pass does not constant fold conditional branch and merge blocks
Hi,
I have a general question on LoopUnswtich pass.
Consider the following IR snippet:
define i32 @test(i1 %cond) {
br label %loop_begin
loop_begin:
br i1 %cond, label %loop_body, label %loop_exit
loop_body:
br label %do_something
do_something:
call void @some_func() noreturn nounwind
br label %loop_begin
loop_exit:
ret i32 0
}
declare void @some_func() noreturn
After running
2007 Jun 11
12
Mocking system/`
This drives me insane on a regular basis. How does one mock
system(''blah'') or `blah` ?
Adding expectations on Kernel doesn''t do it. Adding expectations on
Object just makes me sad:
Object.any_instance.expects(:system).with(''ls'')
# => #<Mock:0x12b584e>.system(''ls'') - expected calls: 0, actual calls: 1
And this really
2007 Feb 05
10
how does Mocha compare in terms of classical vs mock-based testing, and stubbing???
Hi guys,
I''ve just been reading Martin Fowler''s article re mock versus
stubbing<http://martinfowler.com/articles/mocksArentStubs.html>where
he compares traditional TDD testing techniques with mock based
testing. I''d be interested in comments from a ruby on rails perspective in
terms of this and Mocha? For example:
a) Do you see Mocha as a robust way to test Ruby
2006 Oct 25
5
Mocha, Stubba and RSpec
Hi,
I''ve been reading with interest the threads trying to integrate Mocha
and Stubba with RSpec. So far, I''ve made the two changes in
spec_helper.rb suggested, but discovered another one that neither of
the archives mentions:
If you use traditional mocking: object = mock or the stub shortcut
: object = stub(:method => :result), you run into namespace conflicts
with
2007 Mar 12
10
using mocha with rspec
Hi folks.
I''ve just started using rspec and I have to say it''s very nice. The
thing is, I prefer mocha''s mocking dialect. So I thought a simple
require ''mocha'' would set me up.
Unfortunately, rspec does all its goodness using do/end blocks in
anonymous classes, so it wasn''t quite that obvious.
Anyway, here is the incantation I ended up
2006 Sep 08
1
A quick guide to Mocha
Hello :)
Having just gone through the (admittedly simple) API of Mocha to learn
how it works, I wrote a quick guide (190 lines) to help others get up to
speed. I''ve attached it as RDOC and as HTML.
It is a first draft - please help me improve by giving feedback !
Contents :
Overview - Quick overview of Mocha
Unit testing, mock object and stubs - Very quick introduction to mock