Try to fix windows automation tests

This commit is contained in:
Qstick 2020-08-17 23:33:22 -04:00
parent f7bebbaaeb
commit 665a5c89c2
3 changed files with 8 additions and 11 deletions

View File

@ -642,14 +642,14 @@ stages:
failBuild: true
Mac:
osName: 'Mac'
imageName: 'macos-10.14' # Fails due to firefox not being installed on image
imageName: 'macos-10.14'
pattern: 'Radarr.**.osx-core-x64.tar.gz'
failBuild: false
failBuild: true
Windows:
osName: 'Windows'
imageName: 'windows-2019'
pattern: 'Radarr.**.windows-core-x64.zip'
failBuild: $(failOnAutomationFailure)
failBuild: true
pool:
vmImage: $(imageName)
@ -684,9 +684,9 @@ stages:
displayName: Move Package Contents
- bash: |
if [[ $OSNAME == "Mac" ]]; then
url=https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-macos.tar.gz
url=https://github.com/mozilla/geckodriver/releases/download/v0.27.0/geckodriver-v0.27.0-macos.tar.gz
elif [[ $OSNAME == "Linux" ]]; then
url=https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-linux64.tar.gz
url=https://github.com/mozilla/geckodriver/releases/download/v0.27.0/geckodriver-v0.27.0-linux64.tar.gz
else
echo "Unhandled OS"
exit 1

View File

@ -235,7 +235,7 @@ PackageTests()
# geckodriver.exe isn't copied by dotnet publish
if [ "$runtime" = "win-x64" ];
then
curl -Lso gecko.zip "https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-win64.zip"
curl -Lso gecko.zip "https://github.com/mozilla/geckodriver/releases/download/v0.27.0/geckodriver-v0.27.0-win64.zip"
unzip -o gecko.zip
cp geckodriver.exe "$testPackageFolder/$framework/win-x64/publish"
fi

View File

@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using FluentAssertions;
using NLog;
@ -36,10 +36,7 @@ namespace NzbDrone.Automation.Test
{
var options = new FirefoxOptions();
options.AddArguments("--headless");
FirefoxDriverService service = FirefoxDriverService.CreateDefaultService();
// service.Host = "::1"; // Workaround netcore/selenium bug https://github.com/SeleniumHQ/selenium/issues/7840
driver = new FirefoxDriver(service, options, new System.TimeSpan(0, 3, 0));
driver = new FirefoxDriver(options);
_runner = new NzbDroneRunner(LogManager.GetCurrentClassLogger());
_runner.KillAll();