Guidance for AI coding agents (and humans) working in the Appium .NET client. See also CONTRIBUTING.md.
src/Appium.Net/– theAppium.WebDriverlibrary (targetsnetstandard2.0, strong-name signed).test/integration/– NUnit test project (targetsnet48andnet8.0). Holds both server-free tests and functional tests that need an Appium server plus a device, simulator or emulator.Appium.Net.sln– solution used by CI.
dotnet restore Appium.Net.sln
dotnet build Appium.Net.sln --configuration ReleasePrerequisite: Node.js and Appium installed globally (npm install -g appium);
AppiumLocalServerLaunchingTest starts a local Appium server.
CI runs the same filter for net8.0 on Windows, Linux and macOS, and additionally for net48 on Windows:
dotnet test ./test/integration/Appium.Net.Integration.Tests.csproj \
--configuration Release --framework net8.0 \
--filter "AppiumLocalServerLaunchingTest|DirectConnectTest|AppiumClientConfigTest|Tests.Common|Tests.Driver|AppsTest"
# Windows only (single line so it also works in PowerShell)
dotnet test ./test/integration/Appium.Net.Integration.Tests.csproj --configuration Release --framework net48 --filter "AppiumLocalServerLaunchingTest|DirectConnectTest|AppiumClientConfigTest|Tests.Common|Tests.Driver|AppsTest"These need an Appium server and an Android emulator or iOS simulator. Prerequisites, matching CI:
npm install -g appium
# Android
appium driver install uiautomator2
appium driver install espresso # ElementTestEspresso requests the Espresso driver
# iOS (macOS only)
appium driver install xcuitest
brew install ffmpeg # ScreenRecordingTest calls StartRecordingScreenWith the local settings below the tests start Appium themselves via AppiumLocalService, so the appium
CLI and the platform driver must be installed. Against a remote server, that host provides them instead.
CI uses these filters:
# Android (CustomCommandTests lives in the root namespace, so it is matched separately)
dotnet test ./test/integration/Appium.Net.Integration.Tests.csproj --configuration Release --framework net8.0 \
--filter "FullyQualifiedName~Android|FullyQualifiedName~CustomCommand"
# iOS
dotnet test ./test/integration/Appium.Net.Integration.Tests.csproj --configuration Release --framework net8.0 \
--filter "FullyQualifiedName~IOS"Configure env.json first (never commit it):
cp test/integration/env.json.sample test/integration/env.jsonThe sample's defaults do not work as-is:
- Local Appium server: set
"DEV": true(or theDEVenvironment variable). - Remote Appium server: set
"isRemoteAppiumServer": trueand replace theremoteAppiumServerUriplaceholder with the real URL.
See test/integration/README.md for details.
If you cannot run a target framework or a functional suite locally, say so in the PR rather than claiming it passed.
- Follow the style of the surrounding code and
.editorconfig. - Keep the public API backwards compatible unless the change is intentionally breaking; breaking changes must be called out in the PR title (see below).
- Build with no new warnings across all target frameworks.
- Bugfixes and new features ship with tests. If behaviour cannot be covered automatically, explain why in the PR.
- Check the current branch before committing. Start unrelated work on a new branch from
main; do not pile it onto an existing feature branch. - Stage files explicitly. Avoid
git add ./git add -A, which can pick up local artifacts (env.json, test results, tool folders). - Do not commit secrets, credentials, device IDs or local environment files.
- Open PRs against
appium/dotnet-client, branchmain. - The title drives labelling and release notes (
.github/labeler.yml+ Release Drafter). Prefix it with a type:feat:,fix:,refactor:,test:,docs:,build:,ci:,chore:orgithub:. Optional scope, e.g.feat(ios):. Breaking changes usetype!:or includeBREAKING CHANGE:. - Fill in
.github/PULL_REQUEST_TEMPLATE.mdcompletely, including the tests section. - Keep PRs focused: one logical change per PR.
- Do not approve a PR while any CI check is failing, pending or in an unknown state, even if the failure
looks pre-existing on
main. - For a red check: reproduce the build/tests locally, comment with your findings, and request changes if the PR caused the failure.
- Read every unresolved review thread before changing code.
- Make the requested change, add or update tests for it, and build all target frameworks.
- Run the relevant tests, e.g.
dotnet test ./test/integration/Appium.Net.Integration.Tests.csproj --filter "FullyQualifiedName~<TestClassName>". - Stage only the files you changed, commit, and push to the PR branch.
- Reply to each thread (what changed, or why not) and resolve the ones you addressed.