chore(ci): implement robust E2E form testing with puppeteer gatekeeper bypass
All checks were successful
Build & Deploy / 🔍 Prepare (push) Successful in 6s
Build & Deploy / 🧪 QA (push) Successful in 2m16s
Build & Deploy / 🏗️ Build (push) Successful in 3m31s
Build & Deploy / 🚀 Deploy (push) Successful in 13s
Build & Deploy / 🧪 Post-Deploy Verification (push) Successful in 5m23s
Build & Deploy / 🔔 Notify (push) Successful in 1s

This commit is contained in:
2026-02-27 15:05:09 +01:00
parent 7f106b1fa7
commit 44401cf546
2 changed files with 176 additions and 1 deletions

View File

@@ -50,7 +50,12 @@ async function main() {
headers: { Cookie: `klz_gatekeeper_session=${gatekeeperPassword}` },
validateStatus: (status) => status < 400,
});
const filename = `page-${i}.html`;
// Generate a safe filename that retains URL information
const urlStr = new URL(u);
const safePath = (urlStr.pathname + urlStr.search).replace(/[^a-zA-Z0-9]/g, '_');
const filename = `${safePath || 'index'}.html`;
fs.writeFileSync(path.join(outputDir, filename), res.data);
} catch (err: any) {
console.error(`❌ HTTP Error fetching ${u}: ${err.message}`);