Add GitLab CI Phase-1 functional test jobs (#421) #953
No reviewers
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:implement
agent:implement
agent:open_issues
agent:ready
agent:research
agent:security_audit
agent:verify
architecture
backend
blocker:hybrid
blocker:launch
blocker:limit-orders
blocker:v2
block:log_only
block:security
bug
ci
contracts
correctness
deploy
dev
devops
docs
documentation
duplicate
e2e
enhancement
epic
feature
frontend
functional-completion
gas
good first issue
governance
help wanted
high-risk
hooks
hybrid
indexer
infra
infrastructure
integrators
invalid
launch-blocker
limit-orders
localnet
localterra
low priority
missing-implementation
needs-design
ops
performance
priority
high
priority
medium
product
qa
QA
question
ready
ready
research
scripts
security
security-hardening
smartcontracts
tech-debt
testing
ux
UX
v2
verification
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/cl8y-dex-terraclassic!953
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "qa/421-ci-functional-test-jobs"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes the Phase-1 part of #421 — wires the reference functional matrix into GitLab CI so a red functional test actually blocks merge, instead of "GitLab green != functional pass."
What's added
A new
teststage (betweensecurityandbuild), change-gated, MR + default branch, noallow_failure:.github/workflows/test.yml)test-contractscd smartcontracts && cargo testcontracts-terra(test portion)test-indexer-libcd indexer && cargo test --libindexer(lib portion)test-frontendnpm run lint+npm run test:runfrontend(lint + vitest)test-frontend-buildnpm run build(tsc -b + vite) + no-sourcemap assertWhy the build gate
The pipeline never ran a cold
tsc -b, so type-only breaks kept reaching main — #246, then four more across the #337 thread (the latest was aspendableRawbigint-vs-string TS2322 that built fine incrementally but failed cold).npm run lint+vitestdon't catch these;npm run builddoes. The dummyVITE_WC_PROJECT_IDsatisfies the #378 prod-build guard — this gate proves the build compiles, it's not a deployable artifact — and it re-asserts #117 (no sourcemaps in a prod bundle) for free.Design notes
RUSTFLAGSto drop-D warnings(kept on the lint/audit jobs) so a stray test-only warning can't mask a real test signal.cargo test452/0, indexercargo test --lib152/0, frontend build green (0 sourcemaps), lint 0 errors.test-frontend'snpm run test:runincludes the knownterraExplorerlocalhost-vs-127.0.0.1 vitest artifact, which has historically been green in CI/default env but red on some hosts. If it surfaces red in the runner, that test needs an env-pin — a known quantity, not a new break.Out of scope (Phase 2)
Postgres-backed indexer integration (
cargo test --test ...) and Playwright E2E (DinD LocalTerra) are heavier (service containers / DinD) and stay local for now, tracked under #421.Docs
docs/testing.md§ CI: new jobs in the hosted-jobs table + the stage/"CI green" wording.docs/qa-invariants.md: the "not hosted CI" line updated to reflect the GitLab functional gates.Acceptance criteria: contracts + frontend + indexer-lib jobs present, MR + default branch with
rules: changes:, noallow_failure, docs updated. The "break a draft MR and watch it fail" check from the test plan is the first real pipeline run.mentioned in issue #421
Security review — MR !953
Commit reviewed:
54407fc97d466a1ecaaf06309ca082bc10cef7a5Scope:
.gitlab-ci.yml(newteststage:test-contracts,test-indexer-lib,test-frontend,test-frontend-build),docs/testing.md,docs/qa-invariants.mdOutcome:
FINDINGS: 0medium+Security review: no medium+ findings on this diff.
Summary
Reviewed added/modified CI configuration and documentation only — no application, contract, or indexer runtime code changes.
Checked (no issues):
VITE_WC_PROJECT_ID: "ci-build-typecheck"is a non-secret build-time placeholder;test-frontend-buildpublishes no artifacts and thedist/output is ephemeral on the runner.scriptsteps use fixed commands (cargo test,npm ci,npm run build, staticfindguard). No attacker-controlled input reaches shell sinks.rules: changes:on MRs (consistent with existing security-stage audit jobs). Default-branch and scheduled pipelines run the full test matrix. Jobs have noallow_failure— this strengthens merge gates rather than weakening them.rust:1.96-bookworm,node:24-bookworm) match existing pipeline jobs.npm ci/cargo testfollow the same trust model as local Make targets.Inline threads: None (zero medium+ findings).
Automated security review (Cursor Cloud Agent)
added 1 commit
cb6ca031- Add GitLab CI Phase-1 functional test jobs (#421)Compare with previous version
On the pipeline status: config lints clean (GitLab
ci/lintvalid=true). The first push had a real YAML error in the sourcemap-check line (script-not-a-string) — fixed in the amend. The MR pipeline showing red with 0 jobs is the same cross-fork behavior !952 shows: jobs run in the fork context, not on the target-project MR pipeline record, so they don't surface here. The four jobs are validated locally on current main: contractscargo test452/0, indexercargo test --lib152/0, frontendnpm run buildgreen (0 sourcemaps) + lint 0 errors. They run for real on the default-branch pipeline once merged (or a manual web pipeline).Security review — MR !953
Commit reviewed:
cb6ca0312b9c4cc41cf67432d0bc5694e0e2e559Scope:
.gitlab-ci.yml(newteststage:test-contracts,test-indexer-lib,test-frontend,test-frontend-build),docs/testing.md,docs/qa-invariants.mdOutcome:
FINDINGS: 0medium+Security review: no medium+ findings on this diff.
Summary
Re-reviewed the current MR head (prior review was
54407fc; head advanced tocb6ca031). Changes remain CI configuration and documentation only — no application, contract, or indexer runtime code.Checked (no issues):
VITE_WC_PROJECT_ID: "ci-build-typecheck"is a non-secret build-time placeholder that satisfies the #378 production-build guard invite.config.ts;test-frontend-buildpublishes no artifacts anddist/is ephemeral on the runner.scriptsteps are fixed commands (cargo test,npm ci,npm run lint,npm run test:run,npm run build, staticfindguard). No attacker-controlled input reaches shell sinks.rules: changes:on MRs (consistent with existing security-stage audit jobs). Default-branch and scheduled pipelines run the full Phase-1 matrix. Jobs have noallow_failure— this strengthens merge gates rather than weakening them.rust:1.96-bookworm,node:24-bookworm) match existing pipeline jobs.npm ci/cargo testfollow the same trust model as local Make targets; no new unpinned tooling or artifact publishing.Inline threads: None (zero medium+ findings).
Automated security review (Cursor Cloud Agent)
mentioned in commit
5ce57c415e