Skip to content

Instantly share code, notes, and snippets.

View odf's full-sized avatar

Olaf Delgado-Friedrichs odf

View GitHub Profile
@odf
odf / time_in_words.rb
Created July 27, 2011 05:44
Converts time in seconds into English.
module TimeInWords
CONVERSIONS =
[ [:seconds, :years, 31556952], # the average year in the Gregorian calendar
[:seconds, :minutes, 60],
[:minutes, :hours, 60],
[:hours, :days, 24],
[:days, :weeks, 7] ]
UNIT_NAMES =
[ [:years, "year", "years" ],
require File.expand_path(File.dirname(__FILE__) + '/../acceptance_helper')
feature "Approve", %q{
In order to manage workloads and the placement of material
As a manager
I want to approve studies and assign them to archivists
} do
background do
create_user 'Alice'