A unified test automation framework supporting Web, Mobile, and Windows Desktop applications using .NET 8.0 and AI-powered code generation tool.
C#
0
53 commits
updated Jan 18, 2026
A unified test automation framework supporting Web, Mobile, and Windows Desktop applications using .NET 8.0.
This package is available via GitHub Packages. For installation instructions, see CONSUMING_PACKAGE.md.
Quick install (after configuring GitHub Packages):
dotnet add package AIKeyMouse.Automation.Framework
ElementLocator pattern across all platformsAIKeyMouse.Automation.Framework/
βββ DataObjects/ # Data models and locator definitions
β βββ ElementLocator.cs # Unified locator for all platforms
β βββ Locator.cs # Locator strategy enum
β βββ EnumValueAttribute.cs # Attribute for enum values
β βββ MobileDeviceSettings.cs # Mobile device configuration
β βββ MobileDeviceType.cs # Mobile device type enum
β βββ NetworkConditionsData.cs # Network simulation data
βββ Extensions/ # Extension methods for all platforms
β βββ LocatorExtension.cs # Selenium/Appium locator conversion
β βββ LocatorExtension.FlaUI.cs # FlaUI locator conversion
β βββ SearchContextExtension.cs # Web/Mobile element finding with waits
β βββ SearchContextExtension.FlaUI.cs # Windows element finding with waits
β βββ WindowExtension.cs # FlaUI Window helpers
β βββ DriverContextExtension.cs # Driver context helpers
β βββ TestContextExtension.cs # Test context helpers
βββ Infrastructure/ # Core framework classes
β βββ DriverContext.cs # Base driver management
β βββ DriverContextWeb.cs # Web/WebView2 driver management
β βββ DriverContextWindows.cs # Windows app driver management
β βββ DriverContextProperties.cs # Driver context properties
β βββ PageBase.cs # Base class for page objects
β βββ StepsBase.cs # Base class for step definitions
β βββ ConfiguredSettings.cs # Framework configuration
β βββ DriverOptionsSetEventArgs.cs # Event args for driver options
βββ Helpers/ # Helper utilities
β βββ DevToolsHelper.cs # Chrome DevTools Protocol helpers
βββ StepDefinitions/ # Reqnroll step definitions
βββ DevToolsSteps.cs # DevTools-related steps
using AIKeyMouse.Automation.Framework.Infrastructure;
using AIKeyMouse.Automation.Framework.DataObjects;
using AIKeyMouse.Automation.Framework.Extensions;
public class LoginPage : PageBase
{
private ElementLocator UsernameField => new(Locator.Id, "username");
private ElementLocator PasswordField => new(Locator.Id, "password");
private ElementLocator LoginButton => new(Locator.XPath, "//button[@type='submit']");
public void Login(string username, string password)
{
WebDriver.GetElement(UsernameField).SendKeys(username);
WebDriver.GetElement(PasswordField).SendKeys(password);
WebDriver.GetElement(LoginButton).Click();
}
}
using AIKeyMouse.Automation.Framework.Infrastructure;
using AIKeyMouse.Automation.Framework.DataObjects;
using AIKeyMouse.Automation.Framework.Extensions;
public class CalculatorPage : PageBase
{
private ElementLocator Button7 => new(Locator.Id, "num7Button");
private ElementLocator ButtonPlus => new(Locator.Id, "plusButton");
public void Add7Plus5()
{
Window.GetButton(Button7)?.Click();
Window.GetButton(ButtonPlus)?.Click();
// ...
}
}
Unified element locator across all platforms:
// Works for Web, Mobile, and Windows
var element = new ElementLocator(Locator.Id, "myElement");
var element2 = new ElementLocator(Locator.XPath, "//div[@class='test']");
var element3 = new ElementLocator(Locator.Name, "Submit");
| Locator Type | Web/Mobile | Windows (FlaUI) |
|---|---|---|
Id | β | β (AutomationId) |
Name | β | β |
ClassName | β | β |
XPath | β | β |
TagName | β | β (ControlType) |
CssSelector | β | β |
LinkText | β | β |
PartialLinkText | β | β |
AccessibilityId | β (Mobile) | β |
All element finding operations include built-in wait logic:
// Web/Mobile - uses WebDriverWait with configured timeout
var element = searchContext.GetElement(locator); // Default timeout
var element = searchContext.GetElement(locator, TimeSpan.FromSeconds(20)); // Custom timeout
// Windows - uses FlaUI Retry with configured timeout
var element = window.GetElement(locator); // Default timeout
var button = window.GetButton(locator); // Strongly-typed, with wait
Multi-platform driver management:
public class MyTests : StepsBase
{
public void TestWebApp()
{
// Access WebDriver for web/mobile
Driver.WebDriver.Navigate().GoToUrl("https://example.com");
}
public void TestWindowsApp()
{
// Access Windows Application
Driver.StartWindowsApplication(@"C:\Path\To\App.exe");
var window = Driver.Window;
window.GetButton(new ElementLocator(Locator.Id, "btn1"))?.Click();
}
}
Configure timeouts and settings in ConfiguredSettings:
public class ConfiguredSettings
{
public int ShortTimeout { get; set; } = 10; // seconds
public int MediumTimeout { get; set; } = 30;
public int LongTimeout { get; set; } = 60;
}
dotnet restoredotnet buildThis project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
AIKeyMouse Team
A unified test automation framework supporting Web, Mobile, and Windows Desktop applications using .NET 8.0 and AI-powered code generation tool.
C#
0
53 commits
updated Jan 18, 2026
A unified test automation framework supporting Web, Mobile, and Windows Desktop applications using .NET 8.0.
This package is available via GitHub Packages. For installation instructions, see CONSUMING_PACKAGE.md.
Quick install (after configuring GitHub Packages):
dotnet add package AIKeyMouse.Automation.Framework
ElementLocator pattern across all platformsAIKeyMouse.Automation.Framework/
βββ DataObjects/ # Data models and locator definitions
β βββ ElementLocator.cs # Unified locator for all platforms
β βββ Locator.cs # Locator strategy enum
β βββ EnumValueAttribute.cs # Attribute for enum values
β βββ MobileDeviceSettings.cs # Mobile device configuration
β βββ MobileDeviceType.cs # Mobile device type enum
β βββ NetworkConditionsData.cs # Network simulation data
βββ Extensions/ # Extension methods for all platforms
β βββ LocatorExtension.cs # Selenium/Appium locator conversion
β βββ LocatorExtension.FlaUI.cs # FlaUI locator conversion
β βββ SearchContextExtension.cs # Web/Mobile element finding with waits
β βββ SearchContextExtension.FlaUI.cs # Windows element finding with waits
β βββ WindowExtension.cs # FlaUI Window helpers
β βββ DriverContextExtension.cs # Driver context helpers
β βββ TestContextExtension.cs # Test context helpers
βββ Infrastructure/ # Core framework classes
β βββ DriverContext.cs # Base driver management
β βββ DriverContextWeb.cs # Web/WebView2 driver management
β βββ DriverContextWindows.cs # Windows app driver management
β βββ DriverContextProperties.cs # Driver context properties
β βββ PageBase.cs # Base class for page objects
β βββ StepsBase.cs # Base class for step definitions
β βββ ConfiguredSettings.cs # Framework configuration
β βββ DriverOptionsSetEventArgs.cs # Event args for driver options
βββ Helpers/ # Helper utilities
β βββ DevToolsHelper.cs # Chrome DevTools Protocol helpers
βββ StepDefinitions/ # Reqnroll step definitions
βββ DevToolsSteps.cs # DevTools-related steps
using AIKeyMouse.Automation.Framework.Infrastructure;
using AIKeyMouse.Automation.Framework.DataObjects;
using AIKeyMouse.Automation.Framework.Extensions;
public class LoginPage : PageBase
{
private ElementLocator UsernameField => new(Locator.Id, "username");
private ElementLocator PasswordField => new(Locator.Id, "password");
private ElementLocator LoginButton => new(Locator.XPath, "//button[@type='submit']");
public void Login(string username, string password)
{
WebDriver.GetElement(UsernameField).SendKeys(username);
WebDriver.GetElement(PasswordField).SendKeys(password);
WebDriver.GetElement(LoginButton).Click();
}
}
using AIKeyMouse.Automation.Framework.Infrastructure;
using AIKeyMouse.Automation.Framework.DataObjects;
using AIKeyMouse.Automation.Framework.Extensions;
public class CalculatorPage : PageBase
{
private ElementLocator Button7 => new(Locator.Id, "num7Button");
private ElementLocator ButtonPlus => new(Locator.Id, "plusButton");
public void Add7Plus5()
{
Window.GetButton(Button7)?.Click();
Window.GetButton(ButtonPlus)?.Click();
// ...
}
}
Unified element locator across all platforms:
// Works for Web, Mobile, and Windows
var element = new ElementLocator(Locator.Id, "myElement");
var element2 = new ElementLocator(Locator.XPath, "//div[@class='test']");
var element3 = new ElementLocator(Locator.Name, "Submit");
| Locator Type | Web/Mobile | Windows (FlaUI) |
|---|---|---|
Id | β | β (AutomationId) |
Name | β | β |
ClassName | β | β |
XPath | β | β |
TagName | β | β (ControlType) |
CssSelector | β | β |
LinkText | β | β |
PartialLinkText | β | β |
AccessibilityId | β (Mobile) | β |
All element finding operations include built-in wait logic:
// Web/Mobile - uses WebDriverWait with configured timeout
var element = searchContext.GetElement(locator); // Default timeout
var element = searchContext.GetElement(locator, TimeSpan.FromSeconds(20)); // Custom timeout
// Windows - uses FlaUI Retry with configured timeout
var element = window.GetElement(locator); // Default timeout
var button = window.GetButton(locator); // Strongly-typed, with wait
Multi-platform driver management:
public class MyTests : StepsBase
{
public void TestWebApp()
{
// Access WebDriver for web/mobile
Driver.WebDriver.Navigate().GoToUrl("https://example.com");
}
public void TestWindowsApp()
{
// Access Windows Application
Driver.StartWindowsApplication(@"C:\Path\To\App.exe");
var window = Driver.Window;
window.GetButton(new ElementLocator(Locator.Id, "btn1"))?.Click();
}
}
Configure timeouts and settings in ConfiguredSettings:
public class ConfiguredSettings
{
public int ShortTimeout { get; set; } = 10; // seconds
public int MediumTimeout { get; set; } = 30;
public int LongTimeout { get; set; } = 60;
}
dotnet restoredotnet buildThis project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
AIKeyMouse Team