forked from github/scripts-to-rule-them-all
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcibuild
executable file
·39 lines (29 loc) · 839 Bytes
/
cibuild
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/bin/sh
# script/cibuild: Setup environment for CI to run tests. This is primarily
# designed to run on the continuous integration server.
set -e
cd "$(dirname "$0")/.."
echo "Tests started at…"
date "+%H:%M:%S"
# GC customizations
export RUBY_GC_MALLOC_LIMIT=79000000
export RUBY_HEAP_MIN_SLOTS=800000
export RUBY_HEAP_FREE_MIN=100000
export RUBY_HEAP_SLOTS_INCREMENT=400000
export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1
# setup environment
RAILS_ROOT="$(cd "$(dirname "$0")"/.. && pwd)"
export RAILS_ROOT
export RAILS_ENV="test"
export RACK_ROOT="$RAILS_ROOT"
export RACK_ENV="$RAILS_ENV"
test -d "/usr/share/rbenv/shims" && {
export PATH=/usr/share/rbenv/shims:$PATH
}
export RBENV_VERSION="2.1.6"
export PATH="$RACK_ROOT/bin:$PATH"
# run tests
echo "Running tests…"
date "+%H:%M:%S"
# run tests.
script/test