root: specify bin in test

master
Sean Molenaar 2023-02-08 10:38:17 +01:00 committed by BrewTestBot
parent 164cd69bc6
commit 427b6acaa1
No known key found for this signature in database
GPG Key ID: 82D7D104050B0F0F
1 changed files with 4 additions and 4 deletions

View File

@ -143,11 +143,11 @@ class Root < Formula
EOS
# Test ROOT command line mode
system "#{bin}/root", "-b", "-l", "-q", "-e", "gSystem->LoadAllLibraries(); 0"
system bin/"root", "-b", "-l", "-q", "-e", "gSystem->LoadAllLibraries(); 0"
# Test ROOT executable
assert_equal "\nProcessing test.C...\nHello, world!\n",
shell_output("root -l -b -n -q test.C")
shell_output("#{bin}/root -l -b -n -q test.C")
# Test linking
(testpath/"test.cpp").write <<~EOS
@ -158,9 +158,9 @@ class Root < Formula
return 0;
}
EOS
flags = %w[cflags libs ldflags].map { |f| "$(root-config --#{f})" }
flags = %w[cflags libs ldflags].map { |f| "$(#{bin}/root-config --#{f})" }
flags << "-Wl,-rpath,#{lib}/root"
shell_output("$(root-config --cxx) test.cpp #{flags.join(" ")}")
shell_output("$(#{bin}/root-config --cxx) test.cpp #{flags.join(" ")}")
assert_equal "Hello, world!\n", shell_output("./a.out")
# Test Python module