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
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="OpenCvSharp4.runtime.osx_arm64" Version="4.8.1-rc" />
<PackageReference Include="OpenCvSharp4" Version="4.10.0.20241108" />
<PackageReference Include="OpenCvSharp4.runtime.linux-arm" Version="4.10.0.20241107" />
<PackageReference Include="OpenCvSharp4" Version="4.11.0.20250507" />
<PackageReference Include="OpenCvSharp4.runtime.linux-arm" Version="4.11.0.20250506" />
<PackageReference Include="OpenCvSharp4.runtime.osx.10.15-x64" Version="4.6.0.20230105" />
<PackageReference Include="OpenCvSharp4.runtime.win" Version="4.10.0.20241108" />
<PackageReference Include="OpenCvSharp4.runtime.win" Version="4.11.0.20250507" />
<PackageReference Include="OpenCvSharp4_.runtime.ubuntu.20.04-x64" Version="4.10.0.20240616" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Aquality.Selenium.Core" Version="3.2.1" />
<PackageReference Include="Aquality.Selenium.Core" Version="3.3.0" />
<PackageReference Include="WebDriverManager" Version="2.17.5" />
</ItemGroup>

Expand Down
8 changes: 4 additions & 4 deletions Aquality.Selenium/src/Aquality.Selenium/Aquality.Selenium.xml

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

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Aquality.Selenium.Core.Utilities;
using OpenQA.Selenium.DevTools;
using OpenQA.Selenium.DevTools.V135.DOM;
using OpenQA.Selenium.DevTools.V135.Emulation;
using OpenQA.Selenium.DevTools.V137.DOM;
using OpenQA.Selenium.DevTools.V137.Emulation;
using System;
using System.Collections.Generic;
using System.Linq;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using OpenQA.Selenium.DevTools.V135.Performance;
using OpenQA.Selenium.DevTools.V137.Performance;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.13.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.14.0" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using Aquality.Selenium.Tests.Integration.TestApp.TheInternet.Forms;
using NUnit.Framework;
using OpenQA.Selenium;
using OpenQA.Selenium.DevTools.V135.Emulation;
using OpenQA.Selenium.DevTools.V136.Emulation;
using System;
using System.Collections.Generic;

Expand Down Expand Up @@ -59,11 +59,11 @@ public void Should_BePossibleTo_SetAndClearDeviceMetricsOverride_WithVersionSpec
{
void setAction(long width, long height, bool isMobile, double scaleFactor)
{
var parameters = new OpenQA.Selenium.DevTools.V134.Emulation.SetDeviceMetricsOverrideCommandSettings
var parameters = new OpenQA.Selenium.DevTools.V136.Emulation.SetDeviceMetricsOverrideCommandSettings
{
DisplayFeature = new OpenQA.Selenium.DevTools.V134.Emulation.DisplayFeature
DisplayFeature = new OpenQA.Selenium.DevTools.V136.Emulation.DisplayFeature
{
Orientation = OpenQA.Selenium.DevTools.V134.Emulation.DisplayFeatureOrientationValues.Horizontal
Orientation = OpenQA.Selenium.DevTools.V136.Emulation.DisplayFeatureOrientationValues.Horizontal
},
Width = width,
Height = height,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,14 @@ public void Should_BePossibleTo_FindByImage()

var documentByTag = AqualityServices.Get<IElementFactory>().GetLabel(By.TagName("body"), "document by tag");
var fullThreshold = 1;
var documentByImage = AqualityServices.Get<IElementFactory>().GetLabel(new ByImage(documentByTag.GetElement().GetScreenshot().AsByteArray) { Threshold = fullThreshold },
var getDocByImage = () => AqualityServices.Get<IElementFactory>().GetLabel(new ByImage(documentByTag.GetElement().GetScreenshot().AsByteArray) { Threshold = fullThreshold },
"body screen");
ILabel documentByImage = getDocByImage();
AqualityServices.ConditionalWait.WaitForTrue(() =>
{
documentByImage = getDocByImage();
return documentByImage.State.IsDisplayed;
});
Assert.That(documentByImage.State.IsDisplayed, "Should be possible to find element by document screenshot");
Assert.That((documentByImage.Locator as ByImage)?.Threshold, Is.EqualTo(fullThreshold), "Should be possible to get ByImage threshold");
Assert.That(documentByImage.GetElement().TagName, Is.EqualTo("body"), "Correct element must be found");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,12 @@ namespace Aquality.Selenium.Tests.Integration.TestApp.ManyTools.Forms
{
internal abstract class ManyToolsForm<T> : Form where T : ManyToolsForm<T>
{
private const string BaseUrl = "https://manytools.org/";
private const string BaseUrl = "https://manytools.org/";

protected ManyToolsForm(By locator, string name) : base(locator, name)
{
}
private IButton AgreeButton => ElementFactory.GetButton(By.XPath("//button[@mode='primary']"), "Agree");
private ILabel ValueLabel => FormElement.FindChildElement<ILabel>(By.XPath(".//code"), Name);

protected abstract string UrlPart { get; }
Expand All @@ -29,6 +30,12 @@ public T Open()
{
AqualityServices.Browser.GoTo(Url);
AqualityServices.Browser.WaitForPageToLoad();
State.WaitForDisplayed();
if (AgreeButton.State.IsDisplayed)
{
AgreeButton.Click();
AgreeButton.State.WaitForNotDisplayed();
}
}, new List<Type> { typeof(WebDriverTimeoutException) });

return (T)this;
Expand Down
Loading