Skip to content

Commit

Permalink
[bazel] Fix runfiles loading in Bzlmod
Browse files Browse the repository at this point in the history
  • Loading branch information
p0deje committed Apr 18, 2024
1 parent 91b6d4e commit 853b4df
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
4 changes: 2 additions & 2 deletions MODULE.bazel.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dotnet/test/common/Environment/EnvironmentManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ private EnvironmentManager()
try
{
var runfiles = Runfiles.Create();
dataFilePath = runfiles.Rlocation("selenium/dotnet/test/common/appconfig.json");
dataFilePath = runfiles.Rlocation("_main/dotnet/test/common/appconfig.json");
}
catch (FileNotFoundException)
{
Expand Down Expand Up @@ -135,7 +135,7 @@ private EnvironmentManager()
}
else
{
projectRoot += "/selenium";
projectRoot += "/_main";
}

webServer = new TestWebServer(projectRoot, webServerConfig);
Expand Down
2 changes: 1 addition & 1 deletion dotnet/test/common/Environment/TestWebServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public class TestWebServer
{
private Process webserverProcess;

private string standaloneTestJar = @"selenium/java/test/org/openqa/selenium/environment/appserver";
private string standaloneTestJar = @"_main/java/test/org/openqa/selenium/environment/appserver";
private string projectRootPath;
private bool captureWebServerOutput;
private bool hideCommandPrompt;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,7 @@ private String buildServerAndClasspath() {
try {
Runfiles.Preloaded runfiles = Runfiles.preload();
String location =
runfiles
.unmapped()
.rlocation("selenium/java/src/org/openqa/selenium/grid/selenium_server");
runfiles.unmapped().rlocation("_main/java/src/org/openqa/selenium/grid/selenium_server");
System.err.println("Location found is: " + location);
Path path = Paths.get(location);
if (Files.exists(path)) {
Expand Down

0 comments on commit 853b4df

Please sign in to comment.