Skip to content

Instantly share code, notes, and snippets.

kendall :: git/rbx » ruby scratch/bm_either.rb
Rehearsal ---------------------------------------------
includes? 4.410000 0.000000 4.410000 ( 4.421223)
either? 6.450000 0.000000 6.450000 ( 6.478906)
compare 2.040000 0.010000 2.050000 ( 2.044516)
----------------------------------- total: 12.910000sec
user system total real
includes? 4.470000 0.000000 4.470000 ( 4.479386)
either? 6.520000 0.000000 6.520000 ( 6.542424)
require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
class BuildStatusTest < ActiveSupport::TestCase
test "remove the old statii" do
assert_equal 2, BuildStatus.count
BuildStatus.expire_old
statii = BuildStatus.all
assert_equal 1, statii.size
assert statii[0].updated_at >= 30.days.ago
end
# 1) Point *.example.com in your DNS setup to your server.
#
# 2) Setup an Apache vhost to catch the star pointer:
#
# <VirtualHost *:80>
# ServerName example.com
# ServerAlias *.example.com
# </VirtualHost>
#
# 3) Set the current account from the subdomain