Skip to content

Commit 441ae1b

Browse files
committed
Add a test that confirms ruby_bin works fine at runtime
1 parent 4cad3e8 commit 441ae1b

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

ruby/tests/BUILD.bazel

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,22 @@ load(
33
"ruby_binary",
44
)
55

6+
# Tests if :ruby_bin can run in sh_binary
7+
sh_test(
8+
name = "runtime_run_ruby_test",
9+
srcs = ["runtime_run_ruby_test.sh"],
10+
args = [
11+
"$(location args_check.rb)",
12+
"foo",
13+
"bar",
14+
"baz",
15+
],
16+
data = [
17+
"args_check.rb",
18+
"@org_ruby_lang_ruby_host//:ruby_bin",
19+
],
20+
)
21+
622
ruby_binary(
723
name = "args_check",
824
srcs = ["args_check.rb"],
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/sh -e
2+
external/org_ruby_lang_ruby_host/ruby_bin $*

0 commit comments

Comments
 (0)