From 2cc8c4a9cba4f577d4b64b4c31b1480a28313670 Mon Sep 17 00:00:00 2001 From: jamey Date: Thu, 12 Feb 2026 14:40:58 +0000 Subject: [PATCH] add fresh install redirect and admin provider tests Fresh installs now redirect to /users/register instead of showing the demo shop. Post-login redirect goes to /admin dashboard (with setup checklist) instead of /admin/settings. Added 16 provider tests covering index (list, delete, sync) and form (new, edit, test connection). Co-Authored-By: Claude Opus 4.6 --- PROGRESS.md | 4 +- .../live/admin/providers/index.html.heex | 2 +- lib/simpleshop_theme_web/theme_hook.ex | 4 +- lib/simpleshop_theme_web/user_auth.ex | 4 +- .../controllers/page_controller_test.exs | 10 +- .../live/admin/providers_test.exs | 256 ++++++++++++++++++ .../live/shop/cart_test.exs | 7 + .../live/shop/collection_test.exs | 7 + .../live/shop/coming_soon_test.exs | 8 +- .../live/shop/content_test.exs | 7 + .../live/shop/home_test.exs | 7 + .../live/shop/product_show_test.exs | 7 + test/simpleshop_theme_web/user_auth_test.exs | 4 +- 13 files changed, 312 insertions(+), 15 deletions(-) create mode 100644 test/simpleshop_theme_web/live/admin/providers_test.exs diff --git a/PROGRESS.md b/PROGRESS.md index ab81ec8..673933a 100644 --- a/PROGRESS.md +++ b/PROGRESS.md @@ -43,11 +43,11 @@ Plans: [admin-redesign.md](docs/plans/admin-redesign.md) | [setup-wizard.md](doc | ~~11~~ | ~~Theme editor back-to-admin link~~ | 6 | 30m | done | | ~~4~~ | ~~Admin bar on shop pages~~ | — | 1h | done | | ~~12~~ | ~~Consolidate settings page~~ | 6, 7 | 2-3h | done | +| ~~13~~ | ~~Admin dashboard (+ setup checklist)~~ | 6, 7, 9 | 2h | done | +| ~~15~~ | ~~Setup wizard + admin tests~~ | 13 | 1.5h | done | | | **Next up** | | | | -| 13 | Admin dashboard (+ setup checklist) | 6, 7, 9 | 2h | | | 5 | Search (functional search with results) | — | 3-4h | | | | **Needs admin stable** | | | | -| 15 | Setup wizard + admin tests | 13 | 1.5h | | | 16 | Variant refinement with live data | — | 2-3h | | | 17 | Wire real product data to shop pages | — | 2-3h | | | 18 | Shipping costs at checkout | 17 | 2-3h | | diff --git a/lib/simpleshop_theme_web/live/admin/providers/index.html.heex b/lib/simpleshop_theme_web/live/admin/providers/index.html.heex index 441a2be..69f16c2 100644 --- a/lib/simpleshop_theme_web/live/admin/providers/index.html.heex +++ b/lib/simpleshop_theme_web/live/admin/providers/index.html.heex @@ -8,7 +8,7 @@
-