Skip to content

Feat/automated tests#4

Merged
princemuichkine merged 5 commits into
mainfrom
feat/automated-tests
Jun 29, 2026
Merged

Feat/automated tests#4
princemuichkine merged 5 commits into
mainfrom
feat/automated-tests

Conversation

@alphajoop

Copy link
Copy Markdown
Collaborator

Summary

Closes lomiafrica/lomi.#39 (epic lomiafrica/lomi.#45).

Introduces a single CI entry point — run-plugin-tests.sh — that goes beyond static verify-lomi-plugins.sh with structured smoke tests for webhooks, Bubble JSON, and the Woo release zip.

Depends on: #44 (docs/dev-environment) — merge that PR first or rebase this branch onto it.

What’s new

Script Purpose
scripts/run-plugin-tests.sh Orchestrates the full automated suite
scripts/test_webhook_signature.mjs Contract test: HMAC-SHA256 (hex) over raw body
scripts/test_bubble_json.mjs Every *.json under bubble/ must parse
scripts/test_woo_release_zip.sh Build release zip and assert structure (no node_modules, required paths present)
.github/workflows/ci.yml Standalone CI on this repo (submodules: recursive)

Test matrix

run-plugin-tests.sh runs, in order:

  1. verify-lomi-plugins.sh — API contract, integration_source, XOF, branding, legacy brand scan, broken images
  2. Webhook contract — reference HMAC-SHA256 implementation
  3. Bubble JSON smoke — skipped gracefully if submodule is empty
  4. Woo build + release zippnpm install, build, i18n, release.sh, zip inspection

Flags:

  • --fast — steps 1–3 only (no Woo pnpm build)
  • --skip-woo — skip step 4 explicitly

Docs

  • README.md — documents run-plugin-tests.sh as the pre-PR gate
  • E2E.md — links automated suite vs manual E2E matrix

Follow-up (monorepo)

After merge, bump the apps/plugins submodule pointer in lomiafrica/lomi. and land the pending workflow updates:

  • .github/workflows/app-ci-plugins.ymlrun-plugin-tests.sh
  • .github/workflows/app-ci-woo.yml → same (replaces separate verify + build steps)

Out of scope

  • PHPUnit for Woo (no PHPUnit setup today)
  • Live API smoke (LOMI_API_KEY) — stays on Bubble release workflow
  • Manual E2E (Docker + Cloudflare Tunnel) — covered by DEV-ENV.md / E2E.md

Test plan

  • CI green on this PR (submodules: recursive)
  • ./scripts/run-plugin-tests.sh passes locally on Linux/macOS
  • ./scripts/run-plugin-tests.sh --fast passes without Woo build
  • Woo zip step fails if node_modules or resources/ leak into the archive

alphajoop and others added 2 commits June 29, 2026 12:00
Document Alpha local stack (Docker + Cloudflare Tunnel), sandbox checklist,
and dev/woocommerce compose with woo-lomi bind-mount.

Co-authored-by: Cursor <cursoragent@cursor.com>
Introduce run-plugin-tests.sh as the single CI entry point: static parity checks, webhook HMAC contract, Bubble JSON smoke, and Woo build + release zip validation. Add standalone CI workflow on the plugins repo.

Co-authored-by: Cursor <cursoragent@cursor.com>
princemuichkine and others added 2 commits June 29, 2026 22:35
The default checkout token cannot clone the private plugin submodules
(bubble, odoo, shopify), which made `submodules: recursive` abort the
whole checkout. run-plugin-tests.sh only needs woo (the Bubble JSON
smoke test skips gracefully when that submodule is empty), so init the
public submodules explicitly.

Co-authored-by: Cursor <cursoragent@cursor.com>
verify-lomi-plugins.sh hard-required the shopify and bubble submodules,
which are private and not checked out in CI. Guard those platform checks
with plugin_present so the public surface (woo, prestashop, magento) is
validated in CI while private platforms are validated where available,
matching the Bubble JSON smoke test's existing skip behavior.

Co-authored-by: Cursor <cursoragent@cursor.com>
Points woo to b825271 (lomiafrica/woo#9), which declares react/react-dom
as build-time devDependencies so the automated Woo build passes in CI.

Co-authored-by: Cursor <cursoragent@cursor.com>
@princemuichkine princemuichkine merged commit 0167786 into main Jun 29, 2026
1 check passed
@princemuichkine princemuichkine deleted the feat/automated-tests branch June 29, 2026 22:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Plugin automated test suite beyond static parity checks

2 participants