similar to: how to write spec for infinite loop?

Displaying 20 results from an estimated 2000 matches similar to: "how to write spec for infinite loop?"

2008 Mar 08
10
rspec groups?
One of the things I really liked about TestNG was the grouping feature. Are there any plans for rSpec to incorporate that? Is there any way to emulate that functionality in rspec? Will.
2008 Jan 27
8
Textmate RSpec Bundle ''it'' snippet
It seems to me that the RSpec bundle''s ''it'' snippet is in need of some love. By default, a newly inserted spec passes. This seems odd as it is misleading. It also makes it harder find what specs still need to be completed if you return to an RSpec module after a break. I propose that the ''it'' snippet is changed to the following: it
2008 May 10
4
Newbie: lambda do...end.should change(Model, :count).by(1). Doesn''t work
Hi to everyone, I''m an RSpec, and BDD in general, newbie so in order to learn I have chosen to use my personal website as a tesbed. I''m having difficulties juggling with mocks, and in particula with the following code. Here''s the controller action: def create @album = Album.new(params[:album]) if @album.save flash[:notice] = "album saved"
2004 Apr 09
2
Issues with win32-service Daemon
Hi all, I wrote a little echo client to run as a service. I have a couple of problems with this. First, any time I try to define anything in "initialize", the service fails to start. Any idea why? Also, this service runs for a while, then just quits for no reason that I can see. The Event Log merely says, "The Abba service terminated unexpectedly". Any ideas on
2007 Jun 18
7
Testing for cross site scripting, etc.
Being new to testing and ruby, are there "standard" tests that can be done that test for things like cross site scripting and friends? If not, anyone have ideas on what I might do about testing those sorts of things? I''ll be using rails, also. Mike B. ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging
2007 Mar 13
18
Daemonizing a camping server
I''m having no luck trying to daemonize mongrel running a camping server. When mongrel daemonizes, I get: /usr/lib/ruby/gems/1.8/gems/mongrel-1.0.1/lib/mongrel.rb:723:in `accept'': closed stream (IOError) from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0.1/lib/mongrel/configurator.rb:293:in `join'' ... (This was after I disabled the unhandled exception catchall in the
2009 Mar 25
5
[Cucumber] ANN: Cucumber with pure Java
Big news for all Java programmers out there. Now you can use Cucumber with pure Java! That''s right, you don''t have to write a single line of Ruby! (1) All of your step definitions can be written as annotated methods in POJOs (Plain Old Java Objects). To get a taste of what this looks like, check out the simple example in the cucumber_java project on GitHub: * README for
2007 Apr 10
6
getting output of STDOUT in spec
Consider the following method: def name_to_terminal puts "Scott Taylor" end How would I spec this out? Scott
2005 Nov 15
11
Collecting thread: Too many open files (Rails+SCGI crash)
I have a problem with running Rails 0.13.1 with scgi_rails 0.4.3 and Apache. After running for some time (more than a day), the SCGI process stops with the following error (from scgi.log): -- [ERR][24189] Collecting thread: Too many open files [ERR][24189] /usr/local/lib/ruby/gems/1.8/gems/scgi_rails-0.4.3/lib/scgi.rb:188:in `accept''
2007 Aug 22
2
stubbing network calls
I have a couple of methods which make networks calls. Where''s the best place to stub them so they are stubbed for every description automatically? I tried in spec_helper.rb but they are no longer stubbed when a spec runs. at the moment, I''m checking for the test environment in the methods themselves, and returning a dummy value, but I''m sure there''s a better
2019 Nov 15
6
[PATCH 0/3] MST BPC fixes for nouveau
Realized when I moved nouveau over to using the atomic DP MST VCPI helpers that I forgot to ensure that we clamp the BPC to 8 to make us less likely to run out of bandwidth on a topology when enabling multiple displays that support >8 BPC - something we want to do until we have support for dynamically selecting the bpc based on the topology's available bandwidth, since userspace isn't
2007 Dec 19
2
(no subject)
Dear R Users, I am working for the United Nations to construct a complete life table from an abridged table. I want to use the code of Hydman Filter by Rob J Hydman but an error sentence always appears and it simply doesn't run-- source("C:/R/Jamie/HymanFilter.R") Error in .C("spline_coef", method = as.integer(method), n = nx, x = x, : C symbol
2019 Jan 11
20
[PATCH v7 00/20] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Jan 10
21
[PATCH v6 00/20] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2018 Dec 20
22
[PATCH v2 00/16] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2008 Jul 29
1
How to set the parameters in Trellis Graphics (by Lattice package)
Dear R users I plot the trellis graphics by using the lattice package. Everything is OK. Now, I want set some parameters of the trellis graphics. 1. The tick label site. By default, only two tick labels had been output in x-axis of my plot. I want output four or five tick labels. In the traditional graphics system, it will be very easy. Just not output the axis in plot by use the parameter
2007 Aug 14
4
(no subject)
How would you spec out something like the following: def a_method x = Class.new do include Enumerable end # do something here with x end describe "The Anonymous Class" do before :each do @anonymous_class = mock Class Class.stub!(:new).and_return @anonymous_class end it "should create a new anonymous class" do
2012 Jul 14
2
rgamma function
Hi, Has anyone encountered the problem of rgamma function in C? The following simplified program always dies for me, and I wonder if anyone can tell me the reason. #include <Rmath.h> #include <time.h> #include <Rinternals.h> SEXP generateGamma () { srand(time(NULL)); return (rgamma(5000,1)); } Has anyone encountered a similar problem before? Is there another way
2019 Jan 09
27
[PATCH v5 00/20] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2010 Feb 13
4
Important security alert: update your dialplans now!
Friends, Last week, Hans Petter Selansky alerted us of a potential security issue in all releases of Asterisk. In fact, it doesn't involve the code, but the most common way to construct dialplans. If you have something like this in your Asterisk, you need to update your dialplans: [incoming-from-voip] exten => _X., 1, dial(SIP/${EXTEN}) Many VoIP protocols support a large character set,