Skip to content

Commit 7780d3b

Browse files
committed
Box: fix the environment variable name
1 parent f4c4850 commit 7780d3b

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

test/-ext-/box/test_load_ext.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
require 'test/unit'
33

44
class Test_Load_Extensions < Test::Unit::TestCase
5-
ENV_ENABLE_NAMESPACE = {'RUBY_NAMESPACE' => '1'}
5+
ENV_ENABLE_BOX = {'RUBY_BOX' => '1'}
66

77
def test_load_extension
88
pend
@@ -32,7 +32,7 @@ def test_extension_contamination_in_global
3232

3333
def test_load_extension_in_box
3434
pend
35-
assert_separately([ENV_ENABLE_NAMESPACE], "#{<<~"begin;"}\n#{<<~'end;'}")
35+
assert_separately([ENV_ENABLE_BOX], "#{<<~"begin;"}\n#{<<~'end;'}")
3636
begin;
3737
ns = Ruby::Box.new
3838
ns.require '-test-/box/yay1'
@@ -43,7 +43,7 @@ def test_load_extension_in_box
4343

4444
def test_different_version_extensions
4545
pend
46-
assert_separately([ENV_ENABLE_NAMESPACE], "#{<<~"begin;"}\n#{<<~'end;'}")
46+
assert_separately([ENV_ENABLE_BOX], "#{<<~"begin;"}\n#{<<~'end;'}")
4747
begin;
4848
ns1 = Ruby::Box.new
4949
ns2 = Ruby::Box.new
@@ -62,7 +62,7 @@ def test_different_version_extensions
6262

6363
def test_loading_extensions_from_global_to_local
6464
pend
65-
assert_separately([ENV_ENABLE_NAMESPACE], "#{<<~"begin;"}\n#{<<~'end;'}")
65+
assert_separately([ENV_ENABLE_BOX], "#{<<~"begin;"}\n#{<<~'end;'}")
6666
begin;
6767
require '-test-/box/yay1'
6868
assert_equal "1.0.0", Yay.version
@@ -79,7 +79,7 @@ def test_loading_extensions_from_global_to_local
7979

8080
def test_loading_extensions_from_local_to_global
8181
pend
82-
assert_separately([ENV_ENABLE_NAMESPACE], "#{<<~"begin;"}\n#{<<~'end;'}")
82+
assert_separately([ENV_ENABLE_BOX], "#{<<~"begin;"}\n#{<<~'end;'}")
8383
begin;
8484
ns = Ruby::Box.new
8585
ns.require '-test-/box/yay1'

test/ruby/test_box.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def test_proc_defined_in_box_refers_module_in_box
190190
pend unless Ruby::Box.enabled?
191191

192192
# require_relative dosn't work well in assert_separately even with __FILE__ and __LINE__
193-
assert_separately([ENV_ENABLE_NAMESPACE], __FILE__, __LINE__, "here = '#{__dir__}'; #{<<~"begin;"}\n#{<<~'end;'}", ignore_stderr: true)
193+
assert_separately([ENV_ENABLE_BOX], __FILE__, __LINE__, "here = '#{__dir__}'; #{<<~"begin;"}\n#{<<~'end;'}", ignore_stderr: true)
194194
begin;
195195
ns1 = Namespace.new
196196
ns1.require(File.join("#{here}", 'namespace/proc_callee'))
@@ -212,7 +212,7 @@ def test_proc_defined_globally_refers_global_module
212212
pend unless Ruby::Box.enabled?
213213

214214
# require_relative dosn't work well in assert_separately even with __FILE__ and __LINE__
215-
assert_separately([ENV_ENABLE_NAMESPACE], __FILE__, __LINE__, "here = '#{__dir__}'; #{<<~"begin;"}\n#{<<~'end;'}", ignore_stderr: true)
215+
assert_separately([ENV_ENABLE_BOX], __FILE__, __LINE__, "here = '#{__dir__}'; #{<<~"begin;"}\n#{<<~'end;'}", ignore_stderr: true)
216216
begin;
217217
require(File.join("#{here}", 'namespace/proc_callee'))
218218
def Target.foo

0 commit comments

Comments
 (0)