Skip to content

Commit c17ab1e

Browse files
committed
Fixed required path with example location
1 parent 1a41692 commit c17ab1e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spec/bundled_gems_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ def my
247247
build_lib "childprocess", "5.0.0" do |s|
248248
# bootsnap expand required feature to full path
249249
# require 'logger'
250-
rubylibpath = File.expand_path(File.join(__dir__, "..", "..", "lib"))
250+
rubylibpath = File.expand_path(File.join(__dir__, "..", "lib"))
251251
s.write "lib/childprocess.rb", "require '#{rubylibpath}/logger'"
252252
end
253253

@@ -274,7 +274,7 @@ def my
274274
end
275275

276276
it "Show warning with zeitwerk" do
277-
libpath = Dir[File.expand_path(File.join(__dir__, "..", "..", ".bundle", "gems/{zeitwerk}-*/lib"))].map(&:to_s).first
277+
libpath = Dir[File.expand_path("../.bundle/gems/{zeitwerk}-*/lib", __dir__)].map(&:to_s).first
278278
code = <<-RUBY
279279
$LOAD_PATH.unshift("#{libpath}")
280280
require "zeitwerk"

0 commit comments

Comments
 (0)