fix(config): --ios must not silently run an android project#71
Merged
Conversation
…rs runner env resolveProject fell back to projects[0] when an explicit platform matched nothing, so --ios against an android-only config silently ran an android suite with android evidence. It now errors listing the available projects. The CLI preflight also resolved the project from flags alone while the runner honored PLATFORM/NATIVEPROOF_PROJECT, so PLATFORM=ios nativeproof ensured the wrong Appium driver and skipped the macOS guard before running the ios project. Preflight now reads the same env fallback (runSelection).
ea21af0 to
2c2dfe5
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.
Summary
resolveProjectsilently fell back toprojects[0]when an explicit platform matched nothing —npx nativeproof --iosagainst an android-only config ran an Android suite, produced Android evidence, and reported success. It now fails loudly, listing the available projects (a typo'd--projectalready errored; a platform mismatch didn't).PLATFORM/NATIVEPROOF_PROJECTenv vars — soPLATFORM=ios nativeproofensured the uiautomator2 driver and skipped the "iOS requires macOS" guard, then ran the iOS project (late, cryptic session failure). The preflight now uses the same flags-then-env selection (runSelection), so it always preflights the project the runner will actually execute.Proof
npm run checkfix/strict-platform-resolution.npm testrunSelectionenv fallback and flag precedence).Risk
--iossilently running a non-iOS first project now gets an error naming the fix. A strayPLATFORMenv var that the runner was already (silently) honouring now fails fast at preflight instead of steering the run unnoticed.Notes
PR Proof Law
.agents/DEFINITION_OF_DONE.mdand.agents/skills/pr-inline-screenshot-proof/SKILL.md., or the proof section saysNot applicablewith the technical reason.