feat(FN-4202): complete Step 5 — align message inbox wording
Fusion-Task-Id: FN-4202 Fusion-Task-Lineage: 80626869-c2ef-4a57-ba94-e3fe37cfc2b8
This commit is contained in:
@@ -1227,7 +1227,7 @@ export function SettingsModal({
|
||||
const successMessage = providerId === "ntfy"
|
||||
? "Test notification sent — check your ntfy app!"
|
||||
: providerId === "ntfy-message"
|
||||
? "Direct-message test sent — check your ntfy inbox for the agent-to-user message."
|
||||
? "Message inbox test sent — check your ntfy inbox for the agent-to-user message."
|
||||
: providerId === "ntfy-room"
|
||||
? "Room reply test sent — check your ntfy inbox for the room reply."
|
||||
: "Test notification sent — check your webhook endpoint!";
|
||||
@@ -1235,7 +1235,7 @@ export function SettingsModal({
|
||||
addToast(successMessage, "success");
|
||||
} else {
|
||||
const failureMessage = providerId === "ntfy-message"
|
||||
? "Failed to send direct-message test"
|
||||
? "Failed to send message inbox test"
|
||||
: providerId === "ntfy-room"
|
||||
? "Failed to send room reply test"
|
||||
: "Failed to send test notification";
|
||||
@@ -5108,7 +5108,7 @@ export function SettingsModal({
|
||||
!/^[a-zA-Z0-9_-]{1,64}$/.test(form.ntfyTopic)
|
||||
}
|
||||
>
|
||||
{testNotificationLoading["ntfy-message"] ? "Sending…" : "Test direct message"}
|
||||
{testNotificationLoading["ntfy-message"] ? "Sending…" : "Test message inbox"}
|
||||
</button>
|
||||
<button
|
||||
type="button"
|
||||
@@ -5135,7 +5135,7 @@ export function SettingsModal({
|
||||
)}
|
||||
{testNotificationResult["ntfy-message"] && (
|
||||
<small className={`notification-test-feedback-item notification-test-feedback-item--${testNotificationResult["ntfy-message"].status}`}>
|
||||
Direct message: {testNotificationResult["ntfy-message"].message}
|
||||
Message inbox: {testNotificationResult["ntfy-message"].message}
|
||||
</small>
|
||||
)}
|
||||
{testNotificationResult["ntfy-room"] && (
|
||||
|
||||
@@ -3344,7 +3344,7 @@ describe("SettingsModal", () => {
|
||||
await waitForSettingsModalReady();
|
||||
await openNotificationsSection();
|
||||
|
||||
await userEvent.click(screen.getByRole("button", { name: /Test direct message/ }));
|
||||
await userEvent.click(screen.getByRole("button", { name: /Test message inbox/ }));
|
||||
|
||||
await waitFor(() => {
|
||||
expect(mockTestNotification).toHaveBeenCalledWith(
|
||||
@@ -3354,11 +3354,11 @@ describe("SettingsModal", () => {
|
||||
);
|
||||
});
|
||||
expect(addToast).toHaveBeenCalledWith(
|
||||
"Direct-message test sent — check your ntfy inbox for the agent-to-user message.",
|
||||
"Message inbox test sent — check your ntfy inbox for the agent-to-user message.",
|
||||
"success",
|
||||
);
|
||||
expect(screen.getByText("Direct message: Direct-message test sent — check your ntfy inbox for the agent-to-user message.")).toBeInTheDocument();
|
||||
expect(screen.getByText("Direct message: Direct-message test sent — check your ntfy inbox for the agent-to-user message.").closest(".notification-test-feedback")).toHaveAttribute("aria-live", "polite");
|
||||
expect(screen.getByText("Message inbox: Message inbox test sent — check your ntfy inbox for the agent-to-user message.")).toBeInTheDocument();
|
||||
expect(screen.getByText("Message inbox: Message inbox test sent — check your ntfy inbox for the agent-to-user message.").closest(".notification-test-feedback")).toHaveAttribute("aria-live", "polite");
|
||||
});
|
||||
|
||||
it("calls testNotification with ntfy room-event config when room test button clicked", async () => {
|
||||
|
||||
Reference in New Issue
Block a user