fix(deps): keep the end-to-end test framework out of the runtime image #179
Inga granskare
Etiketter
Inga etiketter
area/backups
area/ci
area/control-panel
area/identity
area/infra
area/observability
area/payments
area/security
area/storage
area/web
blocked
needs-info
needs-triage
ready-for-implementation
type
bug
type
chore
type
docs
type
epic
type
feature
type
task
wontfix
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Inget förfallodatum satt.
Beroenden
Inga beroenden satta
Referens
bitborg/bitborg-web!179
Läser in…
Hänvisa till i nytt ärende
Ingen beskrivning angiven.
Ta bort grenen "fix/e2e-deps-out-of-runtime"
Borttagning av en gren är permanent. Även om den borttagna grenen kan fortsätta existera en kort tid innan den faktiskt tas bort, kan det INTE ångras i de flesta fall. Vill du fortsätta?
Closes #178.
nightwatchwas declared independenciesrather thandevDependencies, and the Containerfileinstalls production dependencies only —
pnpm install --prodat both stages. So a WebDriver clientand its whole closure was installed into the image serving the public site:
selenium-webdriver(~18 MB),
nightwatch(~3.3 MB),axe-core(~2.9 MB) and their transitive dependencies.Nothing under
src/imports it. It is used bynightwatch.conf.jsandscripts/e2e.mjs, both ofwhich run only on a developer machine via the
pre-pushhook.Beyond the size, a browser-automation client with no runtime purpose is avoidable attack surface in
a public-facing container.
Verified, not assumed
Lockfile importer section, before and after:
A real
pnpm install --prod --frozen-lockfiletree on this branch:geckodriverwas already correctly placed; onlynightwatchwas wrong.The end-to-end suite still runs — 3 assertions passing — and
pnpm lint,pnpm check(0 errors)and
pnpm test(206 passing) are clean.Why this is separate from the framework question
The same misplacement would ship whichever end-to-end framework is used, so this is worth correcting
on its own rather than folded into #174. It is also the smallest possible change: one entry moved,
lockfile refreshed, no behaviour touched.