Make smoke CI deterministic by removing external API dependency#3
Merged
Conversation
Copilot
AI
changed the title
[WIP] Fix failing GitHub Actions job 'smoke'
Make smoke CI deterministic by removing external API dependency
May 28, 2026
There was a problem hiding this comment.
Pull request overview
This PR makes API smoke validation deterministic in CI by using a local mock contact API unless CONTACT_API_URL is explicitly provided, while documenting the new default behavior.
Changes:
- Adds an in-process mock API for health and contact smoke checks.
- Stops forcing the production API URL in the smoke CI job.
- Updates README validation notes to describe deterministic smoke mode and optional real-endpoint checks.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
scripts/smoke-contact.js |
Adds local mock API startup/teardown and preserves optional external endpoint testing. |
.github/workflows/ci.yml |
Removes the hardcoded CONTACT_API_URL so CI uses the mock path by default. |
README.md |
Documents the updated smoke test behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
The
smokeGitHub Actions job was failing becausenpm run testdepended on reachinghttps://api.vmdev.lat, which is not reliable from CI runners. This change makes smoke validation self-contained by default while preserving optional real-endpoint checks.Smoke script behavior
scripts/smoke-contact.jsnow resolves target URL as:CONTACT_API_URLset → test that endpointGET /api/healthPOST /api/contact(including honeypot path)CI workflow
.github/workflows/ci.ymlsmokejob to stop forcingCONTACT_API_URL, so CI uses deterministic local smoke mode by default.Docs
README.mdquality/validation section to reflect:CONTACT_API_URL