mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-05-06 22:01:44 +08:00
test: wait for auto-sync toggle state after confirmation dialog
This commit is contained in:
@@ -231,6 +231,11 @@ describe("WebdavSyncSection", () => {
|
||||
fireEvent.click(
|
||||
screen.getByRole("button", { name: "confirm.autoSync.confirm" }),
|
||||
);
|
||||
await waitFor(() => {
|
||||
expect(
|
||||
screen.getByRole("switch", { name: "settings.webdavSync.autoSync" }),
|
||||
).toHaveAttribute("aria-checked", "true");
|
||||
});
|
||||
fireEvent.click(screen.getByRole("button", { name: "settings.webdavSync.save" }));
|
||||
|
||||
await waitFor(() => {
|
||||
|
||||
Reference in New Issue
Block a user