Skip to content

Add performance harness binary and server module to automation backend#3

Merged
HarishKarthickS merged 8 commits intoPollux-Studio:mainfrom
HarishKarthickS:feature/backend
Mar 7, 2026
Merged

Add performance harness binary and server module to automation backend#3
HarishKarthickS merged 8 commits intoPollux-Studio:mainfrom
HarishKarthickS:feature/backend

Conversation

@HarishKarthickS
Copy link
Collaborator

This pull request improves how the backend detects and handles explicit paths to the WebView2 browser executable. It introduces a helper function to recognize the msedgewebview2.exe binary and updates the browser launch logic to correctly map such paths to the webview2 runtime. Additionally, it refines the runtime selection logic and adds a dedicated test for this scenario.

WebView2 executable detection and launch logic:

  • Added the is_webview2_executable_path helper function to reliably identify the WebView2 executable by filename.
  • Updated browser_launch_targets to return a webview2 runtime target when an explicit path to msedgewebview2.exe is configured.

Runtime selection logic:

  • Modified preferred_browser_runtime_name to prioritize the webview2 runtime if the configuration points to webview2 or its executable path.

Testing:

  • Added a new test to ensure that providing a direct path to msedgewebview2.exe results in the correct runtime mapping.

Copilot AI review requested due to automatic review settings March 7, 2026 13:42
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves how the automation backend detects and handles explicit paths to the WebView2 browser executable (msedgewebview2.exe). It introduces a is_webview2_executable_path helper to identify the executable by filename, updates browser_launch_targets to return a webview2 runtime target when such a path is configured, and updates preferred_browser_runtime_name to prioritize webview2 in that case.

Changes:

  • Added is_webview2_executable_path helper function (duplicated in both server.rs and perf-harness.rs) to detect the WebView2 binary by filename.
  • Updated browser_launch_targets in both files to short-circuit with a webview2 target when an explicit path to msedgewebview2.exe is configured and the file exists.
  • Updated preferred_browser_runtime_name in server.rs and added/extended tests in both files for the new detection logic.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.

File Description
backend/automation/src/server.rs Adds is_webview2_executable_path, updates browser_launch_targets and preferred_browser_runtime_name, adds new test
backend/automation/src/bin/perf-harness.rs Adds is_webview2_executable_path, updates browser_launch_targets, extends existing test with WebView2 case

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@HarishKarthickS HarishKarthickS merged commit 9df417e into Pollux-Studio:main Mar 7, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants