sadpandajoe commented on code in PR #45649:
URL: https://github.com/apache/superset/pull/45649#discussion_r4394802106
##########
superset-frontend/src/features/semanticLayers/SemanticLayerModal.test.tsx:
##########
@@ -745,3 +772,379 @@ test('A pending clear prevents edits and a closed editor
ignores its late respon
await act(async () => finish({ json: {} }));
expect(props.addSuccessToast).not.toHaveBeenCalled();
});
+
+test('a successful edit after Cancel refreshes the parent without stale modal
UI', async () => {
Review Comment:
The new cases reject the save before the error body is read, so they only
reach the first stale-request check in the catch; the check after `await
getClientErrorObject(error)` is never exercised. If it were removed, a failure
whose body finishes parsing after Cancel would show a danger toast over the
reopened dialog and these tests would still pass. Could a case reject while the
dialog is open, hold `getClientErrorObject` pending, cancel, then resolve it
and assert no danger toast?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]