Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/workflows/e2e-desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,26 @@ jobs:
xvfb-run --auto-servernum pnpm test:e2e
'

- name: Install matching EdgeDriver (Windows)
if: matrix.os == 'windows-latest'
shell: pwsh
run: |
# Tauri uses the WebView2 runtime, not Edge directly.
# msedgedriver must match the WebView2 runtime version, not the Edge browser version.
$wv2Key = 'HKLM:\SOFTWARE\WOW6432Node\Microsoft\EdgeUpdate\Clients\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}'
if (-not (Test-Path $wv2Key)) { $wv2Key = 'HKLM:\SOFTWARE\Microsoft\EdgeUpdate\Clients\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}' }
$wv2Version = (Get-ItemProperty $wv2Key).pv
Write-Host "WebView2 runtime version: $wv2Version"
$driverUrl = "https://msedgewebdriverstorage.blob.core.windows.net/edgewebdriver/$wv2Version/edgedriver_win64.zip"
$zipPath = "$env:TEMP\edgedriver.zip"
$extractDir = "$env:TEMP\edgedriver"
Invoke-WebRequest -Uri $driverUrl -OutFile $zipPath
Expand-Archive -Path $zipPath -DestinationPath $extractDir -Force
$driverDir = "$extractDir\edgedriver_win64"
if (-not (Test-Path "$driverDir\msedgedriver.exe")) { $driverDir = $extractDir }
Write-Host "EdgeDriver path: $driverDir"
echo "$driverDir" | Out-File -Append -Encoding utf8 $env:GITHUB_PATH

- name: Run desktop E2E tests (Windows)
if: matrix.os == 'windows-latest'
run: pnpm test:e2e
Expand Down
8 changes: 8 additions & 0 deletions crates/mcpmux-gateway/src/pool/transport/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ impl HttpTransport {
"access token",
"missing or invalid",
"bearer",
"unexpected content type",
];
oauth_indicators.iter().any(|s| error_lower.contains(s))
}
Expand Down Expand Up @@ -845,6 +846,13 @@ mod tests {
assert!(HttpTransport::requires_oauth("transport channel closed"));
}

#[test]
fn test_requires_oauth_unexpected_content_type() {
assert!(HttpTransport::requires_oauth(
"Unexpected content type: Some(\"text/plain;charset=UTF-8\")"
));
}

#[test]
fn test_requires_oauth_false_for_unrelated() {
assert!(!HttpTransport::requires_oauth("connection refused"));
Expand Down