similar to: rspec with continuations: very strange

Displaying 20 results from an estimated 800 matches similar to: "rspec with continuations: very strange"

2008 Jan 17
5
unusual challenges speccing external software
This is something I''ve come up against twice. First, I have an interactive editor which calls vi, emacs, or TextMate (etc.) via Unix, and then loads the file handed to the editor back into IRB after it''s edited and saved. I guess that makes it a special case of a more general question, which is how do you spec external processes, with a slightly more complicated version of the
2007 Dec 29
5
./script/story command
Below I''ve pasted a ./script/story command I''ve been using for about a week. It has three modes of operation: 1. ./script/story with no arguments will run all *.story files in the story path 2. ./script/story with a path or glob will run the specified stories 3. If input is passed in via STDIN, it runs that text as a story. This opens up story running via a simple interface
2008 Jan 04
7
best way to modify spec (the command-line tool)?
Hi all, where I work we''ve cooked up a kind of ghetto profiler for our specs. It basically just does this: time = Time.now # run the spec puts "woah! dude. long spec." if time > 1.second I''m simplifying here. I think the threshold is actually 0.1 seconds, and we use more precise language, and highlight the spec in red via terminal colors, etc. But the way it works
2008 Jan 26
6
UI Integration with RSpec?
Hi all, Is there any integration with testing tools such as RSpec or Test::Unit planned? I see that the cruise task is run correctly, but the tests show up underneath the build log. Ideally I''d like them to show up the same way that they do in ''java'' CruiseControl, in their own section of tests. Will.
2008 Jan 11
2
guide to good mocking?
Hi all - does anyone know of a good blog post or wiki or something with a good guide to mocking? I''ve got some degree of responsibility for people who are creating mocks. I''m supposed to actually be telling them the best way to do it. In some cases we have code with like a bazillion mock(:x) statements and it''s kind of out of control. I have an idea how the specs should
2008 Jan 31
1
thoughtworks site down? / another tiny patch for Rails 2 compatibility
Hi - couldn''t find the dev list because it appears http://cruisecontrolrb.thoughtworks.com/ is throwing 503 errors. But, to get CCrb running with the new ActiveSupport, I had to do this: http://s3.amazonaws.com/giles/ccrb_duration_patch.jpg (Sorry to submit my patch in JPEG format but you know what they say, anything for a weird life.) The changes are on lines 18 and 27:
2007 Jul 01
1
how many Mongrels?
Hi - I''ve got a pretty popular Rails app on a Mongrel cluster with Apache and mod_proxy_balancer. How do I decide how many Mongrel servers to put in the cluster? I don''t have stats for the number of requests hitting the server yet, but I should have that data soon. The server has 2GB of RAM and has to do a lot of work with RMagick, including generating and storing lots of
2008 Jan 05
5
multi-app merb
Ezra, I love merb, especially because it''s keeping the things that Rails does well and improves on things that Rails hasn''t done so well. One of my biggest pain points with Rails has become multi-app integration. A lot of web sites consist of multiple apps (e.g. a core site, a forum, a blog/cms, etc.). Doing this sort of thing is very ugly and inefficient with the current
2008 Feb 01
0
non-pending spec returning pending
I''m speccing some code which monkey-patches initialize on ActiveResource::Base. The monkey-patch lives in a module. My spec looks like this: describe MyModule, "doing stuff" do it "adds methods to ARes subclasses" do class Thing < ARes::Base ; end (lambda {Thing.new.the_new_method}).should_not raise_error(NoMethodError) end end I did this thing
2006 Mar 08
1
Poor Man''s Continuations
Hi List, I''m a new rubyist and railist, and my web-dev background is php, where I used and contributed to the WACT framework. Continuations are dead cool aren''t they. As I understand it, the problem with having them in rails is that marshalling them isn''t feasbile, so in a stateless environment, they can''t be easily implemented. (Is this correct?) My idea
2008 Mar 30
2
callCC in 2.7.0
Would anyone like to explain if callCC in R 2.7.0 gives anything that on.exit does not already provide? It seems that the exit condition once defined cannot be added to overridden whereas with on.exit multiple on.exit's add additional on.exits rather than being ignored. Is this important?
2018 Feb 27
2
Parallel assignments and goto
Interestingly, the <<- operator is also a lot faster than using a namespace explicitly, and only slightly slower than using <- with local variables, see below. But, surely, both must at some point insert values in a given environment ? either the local one, for <-, or an enclosing one, for <<- ? so I guess I am asking if there is a more low-level assignment operation I can get my
2018 Feb 11
4
Parallel assignments and goto
Hi guys, I am working on some code for automatically translating recursive functions into looping functions to implemented tail-recursion optimisations. See https://github.com/mailund/tailr As a toy-example, consider the factorial function factorial <- function(n, acc = 1) { if (n <= 1) acc else factorial(n - 1, acc * n) } I can automatically translate this into the loop-version
2018 Feb 26
0
Parallel assignments and goto
Following up on this attempt of implementing the tail-recursion optimisation ? now that I?ve finally had the chance to look at it again ? I find that non-local return implemented with callCC doesn?t actually incur much overhead once I do it more sensibly. I haven?t found a good way to handle parallel assignments that isn?t vastly slower than simply introducing extra variables, so I am going with
2008 Dec 08
4
R and Scheme
I've read in many places that R semantics are based on Scheme semantics. As a long-time Lisp user and implementor, I've tried to make this more precise, and this is what I've found so far. I've excluded trivial things that aren't basic semantic issues: support for arbitrary-precision integers; subscripting; general style; etc. I would appreciate corrections or additions from
2018 Feb 27
0
Parallel assignments and goto
No clue, but see ?assign perhaps if you have not done so already. -- Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Tue, Feb 27, 2018 at 6:51 AM, Thomas Mailund <thomas.mailund at gmail.com> wrote: > Interestingly, the
2006 Mar 28
3
coolest software ("coolest startups" re-asked)
Asked a little while back about "coolest startups" using Rails, I think it''d have been better had I asked "coolest software." Besides the obvious (37Signals, Typo, Yakima Herald, Odeo, Measure Map, etc.), I''m just curious about other developments where people are using it to make nifty stuff. -- Giles Bowkett www.gilesgoatboy.org
2006 Apr 22
2
put variable in session each time any controller runs?
Hi -- well, that''s what I''m trying to do. Does anyone know what the best way to do it is? I have three controllers, each one has a hidden tag, and I want each one to salt its respective tag with the name of the action in effect, at the time that action runs, for every action in the controller. -- Giles Bowkett http://www.gilesgoatboy.org
2006 Jul 16
3
pagination over custom-sorted collections?
I have a little web app where we need to paginate collections of items. I''m trying to sort the collection and then pass it, sorted, to a Paginator, and still be able to paginate through the collection, across several pages, with the new sort order. The only thing I''m doing differently from the regular scaffolding approach is this: @order_pages = Paginator.new(self,
2015 Nov 03
26
[Bug 11588] New: missing option: preallocate for all files except for sparse
https://bugzilla.samba.org/show_bug.cgi?id=11588 Bug ID: 11588 Summary: missing option: preallocate for all files except for sparse Product: rsync Version: 3.1.2 Hardware: x64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: core