Commit a113e4e
authored
Non-Admin Support - Webpack & Github Actions (opendatahub-io#6254)
* Fix non-admin test execution with oc user switching and optimized token refresh
- Add oc user switching in cy.visitWithLogin for localhost tests
- Implement lazy token refresh in webpack (5s cache) to avoid blocking event loop
- Add cleanup step for old test artifacts (>2 days)
- Ensure ODH_DASHBOARD_HOST is always passed to webpack
- Add IS_NON_ADMIN_RUN flag to skip admin setup hooks
- Add @ci-dashboard-set-2 tag to non-admin cluster settings test
- Pass OC_SERVER from workflow to Cypress for dynamic user switching
Fixes: Project creation and cluster storage tests that were failing due to
blocking getCurrentToken() calls breaking WebSocket connections.
* Address code review feedback: Make oc login errors fatal and fix cleanup
- Make missing OC_SERVER fatal: Throw error instead of logging warning
- Make oc login failure fatal: Throw error with exit code and output
- Remove Cypress cache cleanup: Avoid deleting binary on shared runners
These changes ensure test failures are explicit when user switching cannot
occur, rather than silently continuing with wrong permissions.
* Mask dashboard URLs and fix hostname extraction
- Add ::add-mask:: for DASHBOARD_URL to prevent exposure in logs
- Add ::add-mask:: for DASHBOARD_HOST to prevent exposure in logs
- Fix sed regex: Use -E flag for proper extended regex (https? instead of https\?)
The previous sed command was broken and extracted 'https:' instead of the
actual hostname. The -E flag enables extended regex where ? means 'optional'
rather than a literal character.
Critical: This prevents sensitive cluster URLs from appearing in CI logs.1 parent 09c12cc commit a113e4e
File tree
5 files changed
+179
-8
lines changed- .github/workflows
- frontend/config
- packages/cypress/cypress
- support/commands
- tests/e2e/settings/clusterSettings
- utils
5 files changed
+179
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
341 | 341 | | |
342 | 342 | | |
343 | 343 | | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
344 | 370 | | |
345 | 371 | | |
346 | 372 | | |
| |||
397 | 423 | | |
398 | 424 | | |
399 | 425 | | |
400 | | - | |
401 | | - | |
402 | | - | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
403 | 435 | | |
404 | 436 | | |
405 | 437 | | |
| |||
457 | 489 | | |
458 | 490 | | |
459 | 491 | | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
460 | 495 | | |
461 | 496 | | |
462 | 497 | | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
463 | 503 | | |
464 | 504 | | |
465 | 505 | | |
| |||
559 | 599 | | |
560 | 600 | | |
561 | 601 | | |
562 | | - | |
563 | | - | |
| 602 | + | |
| 603 | + | |
564 | 604 | | |
565 | 605 | | |
566 | 606 | | |
| |||
599 | 639 | | |
600 | 640 | | |
601 | 641 | | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
602 | 645 | | |
603 | 646 | | |
604 | 647 | | |
| |||
609 | 652 | | |
610 | 653 | | |
611 | 654 | | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
612 | 672 | | |
613 | | - | |
| 673 | + | |
614 | 674 | | |
615 | 675 | | |
616 | 676 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
75 | | - | |
| 76 | + | |
76 | 77 | | |
77 | 78 | | |
78 | 79 | | |
| |||
87 | 88 | | |
88 | 89 | | |
89 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
90 | 121 | | |
91 | 122 | | |
92 | 123 | | |
93 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
94 | 129 | | |
95 | 130 | | |
96 | 131 | | |
| |||
189 | 224 | | |
190 | 225 | | |
191 | 226 | | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
192 | 234 | | |
193 | 235 | | |
194 | 236 | | |
| |||
197 | 239 | | |
198 | 240 | | |
199 | 241 | | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
200 | 249 | | |
201 | 250 | | |
202 | 251 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
313 | 313 | | |
314 | 314 | | |
315 | 315 | | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
316 | 370 | | |
317 | 371 | | |
318 | 372 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
187 | 187 | | |
188 | 188 | | |
189 | 189 | | |
190 | | - | |
| 190 | + | |
191 | 191 | | |
192 | 192 | | |
193 | 193 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
17 | 25 | | |
18 | 26 | | |
19 | 27 | | |
| |||
0 commit comments