@madie/madie-design-system 1.2.55 → 1.2.56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@madie/madie-design-system",
3
- "version": "1.2.55",
3
+ "version": "1.2.56",
4
4
  "description": "Shared style guide across the Madie program.",
5
5
  "main": "dist/index.js",
6
6
  "homepage": "https://github.com/MeasureAuthoringTool/madie-design-system",
@@ -39,6 +39,9 @@ describe("MadieDeleteDialog", () => {
39
39
  expect(
40
40
  queryByText("Are you sure you want to delete ?")
41
41
  ).toBeVisible();
42
+ expect(
43
+ queryByText("This Action cannot be undone.")
44
+ ).toBeVisible();
42
45
  });
43
46
  });
44
47
  });
@@ -81,4 +84,28 @@ describe("MadieDeleteDialog", () => {
81
84
  });
82
85
  });
83
86
  });
87
+
88
+ test("Dialog has not warning text", async () => {
89
+ await act(async () => {
90
+ const { getByTestId, queryByText } = await render(
91
+ <MadieDeleteDialog
92
+ open={true}
93
+ onClose={() => setDialogOpen(false)}
94
+ onContinue={() => setDialogOpen(false)}
95
+ hideWarning={true}
96
+ />
97
+ );
98
+
99
+ const deleteDialog = await getByTestId("delete-dialog");
100
+ expect(deleteDialog).toBeInTheDocument();
101
+ await waitFor(() => {
102
+ expect(
103
+ queryByText("Are you sure you want to delete ?")
104
+ ).toBeVisible();
105
+ expect(
106
+ queryByText("This Action cannot be undone.")
107
+ ).not.toBeInTheDocument();
108
+ });
109
+ });
110
+ });
84
111
  });