QAssistant 1.1.0
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package QAssistant --version 1.1.0
NuGet\Install-Package QAssistant -Version 1.1.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="QAssistant" Version="1.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add QAssistant --version 1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: QAssistant, 1.1.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install QAssistant as a Cake Addin #addin nuget:?package=QAssistant&version=1.1.0 // Install QAssistant as a Cake Tool #tool nuget:?package=QAssistant&version=1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
QAssistant
QAssistant is created for testers who is working for UI automation using Selenium and WebDriver.
Installation
Use the package manager to install QAssistant
Install-Package QAssistant
or the .NET CLI.
dotnet add package QAssistant
Usage example
using NUnit.Framework;
using OpenQA.Selenium;
using OpenQA.Selenium.Chrome;
using QAssistant.Extensions;
namespace Tests
{
public class ExtensionTests
{
private IWebDriver _driver;
[SetUp]
public void Setup()
{
var opts = new ChromeOptions();
opts.AddArgument("--start-maximized");
_driver = new ChromeDriver(opts);
_driver.Navigate().GoToUrl("https://google.com");
}
[Test]
public void TestReadFromFieldValueOnSuccess()
{
Assert.IsEmpty(_driver.ReadFromFieldValue(By.Name("q")));
}
[TearDown]
public void CloseBrowser()
{
_driver.CloseAndDispose();
}
}
}
QAssitant 1.1.0
December 28, 2020
New Features
- TakeScreenshot - Extension methods to take screenshot of the current page and save it with default parameters or pass the image file name, path and format. You can also get screenshot as "AsByteArray" or "AsBase64EncodedString".
- RandomGenerator - Helper to generate random symbols, letters, numbers or combination of them. It will be helpful in various cases when it is important to generate random strings or numbers.
- ElementIdentifier - Custom attribute for properties. It is created for POM object properties to mark and access them from another classes easly.
Example:
[ElementIdentifier("logoelement")]
public IWebElement Logo => _driver.WaitUntilElementIsDisplayed(By.Id("hplogo"));
- ElementFinder - Helper for POM properties to access them with property names or element identifiers from another classes.
Example:
private ElementFinder<GooglePage> _elementFinder;
[SetUp]
public void Setup()
{
_driver = new ChromeDriver(opts);
_googlePage = new GooglePage(_driver);
_elementFinder = new ElementFinder<GooglePage>();
_driver.Navigate().GoToUrl("https://google.com");
}
[Test]
public void TestElementIdentifierOnSuccessWithElementIdentifier()
{
Assert.True(typeof(RemoteWebElement) == _elementFinder.FindElement(_googlePage, "logoelement").GetType());
}
[Test]
public void TestElementIdentifierOnSuccessWithPropertyName()
{
Assert.True(typeof(RemoteWebElement) == _elementFinder.FindElement(_googlePage, "Logo").GetType());
}
- WaitUntilElementIsDisplayed - Extension method finds the first "IWebElement" using the given method and condition and waits for it's visibility.
- HoverOnElement, ElementExists, GetParent, GetChild, GetPreviousSibling, GetNextSibling - Extension methods
Changes
- WaitUntilFindElement extension method now finds the first "IWebElement" using the given method and condition and waits for it's existence.
Bug Fixes
- Some bug fixes and improvements...
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
License
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp3.1 is compatible. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETCoreApp 3.1
- Selenium.WebDriver (>= 3.141.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.