mirror of
https://github.com/rbenv/ruby-build.git
synced 2025-06-18 01:38:05 +02:00
parent
e466bfeab0
commit
da840a82a1
2 changed files with 17 additions and 2 deletions
test
|
@ -2,6 +2,7 @@
|
|||
|
||||
load test_helper
|
||||
export RUBY_BUILD_CACHE_PATH="$TMP/cache"
|
||||
export MAKE=make
|
||||
|
||||
setup() {
|
||||
mkdir -p "$INSTALL_ROOT"
|
||||
|
@ -32,8 +33,8 @@ OUT
|
|||
}
|
||||
|
||||
stub_make_install() {
|
||||
stub make \
|
||||
' : echo make "$@" >> build.log' \
|
||||
stub "$MAKE" \
|
||||
" : echo \"$MAKE \$@\" >> build.log" \
|
||||
"install : cat build.log >> '$INSTALL_ROOT/build.log'"
|
||||
}
|
||||
|
||||
|
@ -92,3 +93,16 @@ OUT
|
|||
assert_success
|
||||
assert [ -x ./here/bin/package ]
|
||||
}
|
||||
|
||||
@test "make on FreeBSD defaults to gmake" {
|
||||
cached_tarball "ruby-2.0.0"
|
||||
|
||||
stub uname "-s : echo FreeBSD"
|
||||
MAKE=gmake stub_make_install
|
||||
|
||||
MAKE= install_fixture definitions/vanilla-ruby
|
||||
assert_success
|
||||
|
||||
unstub gmake
|
||||
unstub uname
|
||||
}
|
||||
|
|
1
test/fixtures/definitions/vanilla-ruby
vendored
Normal file
1
test/fixtures/definitions/vanilla-ruby
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
install_package "ruby-2.0.0" "http://ruby-lang.org/ruby/2.0/ruby-2.0.0.tar.gz"
|
Loading…
Reference in a new issue