Conversation
IsTrue dereferenced its value after a null-conditional chain, so ServerIsLocal() threw NullReferenceException whenever env.json had DEV=false and the DEV environment variable was unset, failing OneTimeSetUp for every fixture that calls it.
…tests (appium#1135) These fixtures picked the Appium server URI with ServerIsLocal(), which reflects the DEV flag rather than isRemoteAppiumServer. In CI DEV is false, so they always resolved to RemoteServerUri (localhost:4723) with nothing listening there, only "passing" by luck of test order when another fixture had already started a local Appium service on the same default port. Switch to ServerIsRemote(), matching the pattern already used by the rest of the suite (e.g. ClipboardTest.cs), so these fixtures reliably start/use the local Appium service in CI.
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Add automated coverage for enabled and default-off plugin configurations.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 1
Open (1)
What changed in this PR
Enables Appium’s images plugin for local integration tests through opt-in configuration.
Changes:
- Reads configuration from
env.jsonorAPPIUM_USE_IMAGES_PLUGIN. - Conditionally activates the images plugin.
- Documents the setting in the sample configuration.
| File | Summary |
|---|---|
test/integration/helpers/Env.cs |
Resolves images-plugin configuration. |
test/integration/helpers/AppiumServers.cs |
Conditionally activates the plugin. |
test/integration/env.json.sample |
Documents the opt-in setting. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+25
to
+27
| if (Env.UseImagesPlugin()) | ||
| { | ||
| args.AddArguments(new KeyValuePair<string, string>("--use-plugins", "images")); |
ImagesComparisonTests has been failing with NotImplementedException ("The
requested resource could not be found") since Appium 2 moved the
compare_images endpoint out of the server and into the images plugin. The
plugin only serves that route when it is activated at server start, and
AppiumServers started the local service with --relaxed-security alone, so
the route was never mounted.
Pass --use-plugins=images when the new useImagesPlugin setting (env.json)
or the APPIUM_USE_IMAGES_PLUGIN environment variable is set. The flag is
opt-in rather than unconditional because Appium exits with "Could not load
the plugin 'images' because it is not installed" when the plugin is
missing, which would break every local-service run, including
AppiumLocalServerLaunchingTest. Default-off keeps the current CI behaviour
unchanged.
Verified locally on Windows against Appium 3.7.0 with
appium-windows-driver 6.3.0 and images@5.0.0: the three
ImagesComparisonTests tests pass with the flag enabled, the 21
AppiumLocalServerLaunchingTest tests still pass with it unset, and the
Windows suite goes from 7/13 to 10/13.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011ioB36iPHdGs87Nx5A8HHe
Dor-bl
force-pushed
the
test/images-plugin-opt-in
branch
from
September 24, 2026 18:17
bcf2802 to
7b6874c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

ImagesComparisonTests has been failing with NotImplementedException ("The
requested resource could not be found") since Appium 2 moved the
compare_images endpoint out of the server and into the images plugin. The
plugin only serves that route when it is activated at server start, and
AppiumServers started the local service with --relaxed-security alone, so
the route was never mounted.
Pass --use-plugins=images when the new useImagesPlugin setting (env.json)
or the APPIUM_USE_IMAGES_PLUGIN environment variable is set. The flag is
opt-in rather than unconditional because Appium exits with "Could not load
the plugin 'images' because it is not installed" when the plugin is
missing, which would break every local-service run, including
AppiumLocalServerLaunchingTest. Default-off keeps the current CI behaviour
unchanged.
Verified locally on Windows against Appium 3.7.0 with
appium-windows-driver 6.3.0 and images@5.0.0: the three
ImagesComparisonTests tests pass with the flag enabled, and the Windows
suite goes from 7/13 to 10/13.
Co-Authored-By: Claude Opus 5 (1M context) noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_011ioB36iPHdGs87Nx5A8HHe