Skip to content

Instantly share code, notes, and snippets.

def account
@account ||= Factory.build(:account)
end
Given /^I have a valid account$/ do
account
# require 'rubygems'; require 'ruby-debug'; debugger
end
_crcWarningList :: IORef CRCWarningList
_crcWarningList = unsafePerformIO $ newIORef []
addCRCWarning :: FilePath -> IO ()
addCRCWarning fp = modifyIORef _crcWarningList (fp:)
getCRCWarnings :: IO [FilePath]
getCRCWarnings = readIORef _crcWarningList
resetCRCWarnings :: IO ()
You can view your tunneled connection at http://web1.tunnlr.com:9901/
When I post the following to the "simple" api: # features/step_definitions/global_steps.rb:13
| title | form_html | price | identifier |
| Review Image | {{html('form_html')}} | "0.01" | Image Mod |
expected "200"
got "422"
Without Changes
real 13m38.415s
user 0m4.148s
sys 0m1.060s
With Changes
real 0m55.679s
user 0m1.092s
sys 0m0.240s
import Network.HTTP
import System.Timeout
main = do
rsp <- timeout 1000000 $ simpleHTTP $ getRequest "http://10.1.2.3/S"
case rsp of
Just rsp -> return rsp
Nothing -> error "Nothing"
worker = TaskGroupWorker.new(:turk_worker_id => turk_assignment.WorkerId)
task_group.task_group_workers << worker
Where should we check if the TaskGroupWorker was created ?
assignment = Factory(:turk_assignment, :AssignmentStatus => 'Approved')
task_group = Factory(:task_group)
assignment.task.identifier = task_group.name
assignment.task.account = task_group.account
assignment.save
plural (Noun s) | "y" `isSuffixOf` s
&& length s > 1
&& not (last (init s) `elem` "aeiou") = showString (init s) . showString "ies"
-- Copyright (C) 2005 Tomasz Zielonka
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2, or (at your option)
-- any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the