GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add saved tenant SMTP test action in Admin by Storypapst · Pull Request #1095 · OpenResilienceInitiative/ORISO-Admin

Conversation

@Storypapst

@Storypapst Storypapst commented Sep 26, 2026 •
edited by coderabbitai Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Collaborator

A Träger can save its own mail server in Admin, but it cannot tell whether the server will accept mail. This adds a test action beside the settings. The test sends only to the signed-in administrator's verified address through the saved Träger server; the browser supplies no recipient or SMTP password.

What we need to do

  • Offer the test only after a complete OWN server has been saved. PLATFORM mode and an unsaved server cannot be tested here.
  • Show a clear result when the server accepts a message, the administrator's email is not verified, settings are incomplete, the cooldown applies or the server cannot confirm delivery.
  • Keep the request body empty and let TenantService choose the verified destination and stored credentials.

Current state — 2 October 2026

The saved-server test action is already on dev: Admin #1076 merged it on 1 October together with #1094. Before today this branch added nothing beyond dev. Commit df660976 adds the one missing check: a test that each answer of the test endpoint (403, 404, 422, 429, 502) shows its own plain message in place, and that a 403 does not send the Admin page to "access denied". The endpoint itself still needs TenantService #291 merged and deployed; until then Dev answers 404 and the button shows the general error.

For developers — verification (skip if you only need the status):

Head df660976 = 1b1e54b7 + one test-only commit (SmtpSettings.smtp-wire.test.tsx).
Local, Node 22.12.0: wire test file 10/10; mutation check (429 key swapped, 403 redirect restored) fails 2 tests as expected.
ESLint --max-warnings=0, Prettier, tsc --noEmit: pass. Full unit suite not re-run locally.
Contract checked against TenantService #291 (api/tenant-smtp-test.yaml at 9fcfdb1d): 204/400/401/403/404/422/429 Retry-After 60/502, empty body.

How to test it quickly

  • With saved OWN settings, the Admin action calls the tenant test endpoint with only the tenant ID.
  • With PLATFORM or incomplete/unsaved OWN settings, the action is disabled.
  • Twenty focused UI/API tests, TypeScript, ESLint, Prettier, production build and forbidden-host validation passed locally at the earlier head. At dcb42ff5, a 403 from the test endpoint stays in this form and shows the verified-account explanation instead of redirecting the whole Admin page. The API contract test failed before the fix; 38 targeted API/client/form tests, TypeScript, ESLint, Prettier and diff check pass locally.
  • On deployed Dev, use a verified tenant admin to receive one test mail, then try a second within a minute and a deliberately failing server.

Still open

  • This branch stacks on Admin #1094, which stacks on #1076. TenantService #291 supplies the endpoint and itself depends on chore(coderabbit): enable auto review on dev #290 and test(user-list): lock in the sort fallback that prevents endless loading (#77) #278.
  • New-head CI and human review remain open. TenantService Permission cascade: Platform → Träger → Beratungsstelle + enforced-on (ADR-013) #291 at edc5c14 has all seven current-head CI checks green; merge, Dev deployment and mailbox proof remain open.

For developers — request contract:

POST ${tenantEndpoint}${tenantId}/smtp-test-deliveries
No request body, recipient or credentials. TenantService reads the JWT and stored OWN settings.
Base: dev. Dependencies: Admin #1076 -> #1094; TenantService #278 -> #290 -> #291.

Refs #1061

Conflict repair — 1 October 2026

This older parallel branch is now conflict-free and contains exactly the same source as the canonical SMTP mode PR1076. It adds no separate feature. Review and integrate PR1076 as the canonical package; retain this branch as delivery history.

For developers — conflict repair and local evidence:

Commit: 1b1e54b704b9503d34d7ca2cdeda38dede361f49
Parents: dcb42ff53a627eb374c05f976416e305ba92b63e + 63bdb5d034e24571f57b5ade35c68cd63a6c5389
Tested/reviewed tree: 3cb816bcf8c0aa5b81cb282600962998fdbe2520
Node22.12.0: 177 relevant tests in8files passed; the previous-timeout test passed separately unchanged (1passed,53deliberatelyfiltered).
Final format, exact CI ESLint, stylelint, Storybook types, build/postbuild and diff checks: exit0.
Earlier full suite: EXIT1 despite3663passed assertions (worker termination). One full retry STOPPED_NONPASS after inherited AccountInvites fixture timeout; no complete new full-suite PASS claimed.
Final18incoming files exactcurrentdev03eb; checkpoint locale values and newlanguageError keys retained.
Independent source and all gate/log/result/source hashes verified. Historical branches have exact whole-tree identity to tested1076; no redundant suites.
Independent source review: PASS. Normal push; no force-push or GitHub merge.
Fresh CI, human review, merge, deployment and received mail are separate gates.

Summary by CodeRabbit

  • Tests
    • Added coverage for SMTP test-delivery error responses, checking that the appropriate error appears without a success message and that the page URL remains unchanged.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@coderabbitai

coderabbitai Bot commented Sep 26, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

🧰 Additional context used
📚 Code guidelines (2)
AGENTS.md — configured
.understand-anything/ARCHITECTURE.md — configured

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: OpenResilienceInitiative/ORISO-Admin/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Team

Run ID: 4c88dc0a-4af2-4ab4-8806-61c37e7f433a

📥 Commits

Reviewing files that changed from the base of the PR and between c2820c4 and c8934fa.

📒 Files selected for processing (1)
  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx

Included review availability: This review used your included allowance. 5 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 6 reviews per hour.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (7)
  • GitHub Check: Unit tests (shard 4/4)
  • GitHub Check: Unit tests (shard 1/4)
  • GitHub Check: Unit tests (shard 3/4)
  • GitHub Check: Storybook component tests (interactions + a11y)
  • GitHub Check: Unit tests (shard 2/4)
  • GitHub Check: build
  • GitHub Check: build
🧰 Additional context used
📓 Path-based instructions (5)
Tests should prove the failing/admin-visible behavior and relevant edge cases.

⚙️ CodeRabbit configuration file

Files:

  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
Check admin behavior against the surrounding ORISO workflow, not only types.

⚙️ CodeRabbit configuration file

Files:

  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
Reuse existing design tokens and components; avoid hardcoded styling for repeated controls, table states, or responsive layout.

📄 CodeRabbit inference engine (AGENTS.md)

Files:

  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
Shared UI modules under `src/components/**` should contain page shells, listing tables, resizable tables, segmented tabs, search input, forms, tenant setting components, legal-text editors, language selector, layout/nav icons, and related r...

📄 CodeRabbit inference engine (.understand-anything/ARCHITECTURE.md)

Files:

  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
Reuse existing table, form, query, mutation, role, and validation patterns instead of adding local one-off flows.

📄 CodeRabbit inference engine (AGENTS.md)

Files:

  • src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
🔇 Additional comments (1)
src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx (1)

168-190: LGTM!


📝 Walkthrough

Walkthrough

Parameterized component tests cover SMTP test-delivery responses with HTTP statuses 403, 404, 422, 429, and 502. They verify the error notification, absence of a success notification, one write request, and unchanged page URL.

Changes

SMTP delivery tests

Layer / File(s) Summary
Delivery error response assertions
src/components/Tenants/AppSettings/SmtpSettings/SmtpSettings.smtp-wire.test.tsx
Parameterized tests map five HTTP statuses to their error messages. Each case checks notifications, write-request count, and navigation behavior.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~4 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to c8934

The new tests cover the reported SMTP error responses, and existing coverage checks the request shape. No actionable merge risk remains from the reviewed changes.

🚥 Pre-merge checks | ✅ 7
✅ Passed checks (7 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title names the ORISO Admin area and the saved tenant SMTP test action. It is related to the tested SMTP feature, although the changeset adds tests rather than the action itself.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Validation Evidence ✅ Passed PASS. The reviewed range changes only SmtpSettings.smtp-wire.test.tsx; it adds parameterized automated coverage for 403, 404, 422, 429, and 502 responses. The PR description also reports the focused…
Shared Admin Patterns ✅ Passed PASS. The authoritative diff changes only SmtpSettings.smtp-wire.test.tsx; it adds no UI, form, table, role, API, or validation implementation. The tests exercise the existing SmtpSettings compone…
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Comment @coderabbitai help to get the list of available commands.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Storypapst
Storypapst requested review from Shirloin, nikunjdecyb and shanzaeimran September 26, 2026 14:43
This was referenced Sep 26, 2026
Send tenant SMTP test mail to verified admin address OpenResilienceInitiative/ORISO-TenantService#291
Merged
Träger mail settings: check that port and SSL fit, and offer a test mail #1061
Closed
EPIC: transactional e-mails — one design system across every sending path OpenResilienceInitiative/ORISO-Frontend#828
Open
Decide: does a Träger without its own mail server send through the platform server? OpenResilienceInitiative/ORISO-Frontend#1562
Closed
Persist explicit tenant mail-server choice without copying platform SMTP #1076
Merged
@Storypapst Storypapst added this to ORISO Roadmap Oct 1, 2026
@Storypapst
Merge tested canonical SMTP integration into historical PR1095
1b1e54b
This historical branch is fully contained in PR1076. Retain its history while using the exact tested current-dev-compatible canonical tree; do not revive the old OWN/PLATFORM validation. This is provenance, not an independent feature delivery or new human approval.
@Storypapst
Storypapst marked this pull request as ready for review October 1, 2026 22:42
@Storypapst Storypapst self-assigned this Oct 1, 2026
@Storypapst
Storypapst requested a review from shazia-k October 1, 2026 22:42
Storypapst and others added 3 commits October 2, 2026 00:58
@Storypapst @claude
test(smtp): pin the in-place message for each tenant test response
df66097
Covers 403, 404, 422, 429 (with Retry-After) and 502 from
POST /tenant/{id}/smtp-test-deliveries through the real fetch path, and
that a 403 no longer redirects the Admin page.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@shazia-k
Merge branch 'dev' into feat/1061-tenant-smtp-test-button
b1f0658
@shazia-k
Merge branch 'dev' into feat/1061-tenant-smtp-test-button
c8934fa
@shazia-k
shazia-k enabled auto-merge October 2, 2026 11:12
coderabbitai[bot]
coderabbitai Bot approved these changes Oct 2, 2026
View reviewed changes
@shazia-k
shazia-k merged commit eb124d8 into dev Oct 2, 2026
12 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@shazia-k
shazia-k deleted the feat/1061-tenant-smtp-test-button branch October 2, 2026 11:16
@Hassan9215 Hassan9215 mentioned this pull request Oct 8, 2026
Release Admin v2.0.11 #1161
Merged
@Storypapst Storypapst moved this from In review to QA internal in ORISO Roadmap Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@coderabbitai coderabbitai[bot] coderabbitai[bot] approved these changes
@shanzaeimran shanzaeimran Awaiting requested review from shanzaeimran
@Shirloin Shirloin Awaiting requested review from Shirloin
@nikunjdecyb nikunjdecyb Awaiting requested review from nikunjdecyb
@shazia-k shazia-k Awaiting requested review from shazia-k

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@Storypapst Storypapst

Labels

None yet

Projects

ORISO Roadmap
Status: QA internal

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@Storypapst @shazia-k
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.