Skip to content

Commit 012e883

Browse files
committed
Add test task
1 parent aeaf9bd commit 012e883

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed

Rakefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
11
require 'nanoc3/tasks'
2+
require 'html/proofer'
23

34
desc "Compile the site"
45
task :compile do
56
`nanoc compile`
67
end
78

9+
desc "Test the output"
10+
task :test => [:compile] do
11+
HTML::Proofer.new("./output").run
12+
end
13+
814
# Prompt user for a commit message; default: P U B L I S H :emoji:
915
def commit_message
1016
publish_emojis = [':boom:', ':rocket:', ':metal:', ':bulb:', ':zap:',

script/cibuild

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/bin/sh
2+
# Usage: script/cibuild
3+
# CI build script
4+
#
5+
set -e
6+
7+
# GC customizations
8+
export RUBY_GC_MALLOC_LIMIT=79000000
9+
export RUBY_HEAP_MIN_SLOTS=800000
10+
export RUBY_HEAP_FREE_MIN=100000
11+
export RUBY_HEAP_SLOTS_INCREMENT=400000
12+
export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1
13+
14+
export PATH="/usr/share/rbenv/shims:$PATH"
15+
export RACK_ROOT=$(cd "$(dirname $0)"/.. && pwd)
16+
export RACK_ENV="test"
17+
export RAILS_ENV="test"
18+
export RBENV_VERSION="1.9.3"
19+
20+
# clean out the ruby environment
21+
export RUBYLIB=
22+
export RUBYOPT=
23+
24+
# bootstrap gem environment changes
25+
cd "$RACK_ROOT"
26+
echo 'Bootstrapping gems...'
27+
script/bootstrap
28+
29+
rake test

0 commit comments

Comments
 (0)