mirror of
https://gitee.com/spark-store-project/spark-store
synced 2026-06-22 22:23:49 +08:00
fix(account): trim forum login password
This commit is contained in:
@@ -9,8 +9,8 @@ describe("LoginModal", () => {
|
|||||||
props: { show: true, loading: false, error: "" },
|
props: { show: true, loading: false, error: "" },
|
||||||
});
|
});
|
||||||
|
|
||||||
await fireEvent.update(screen.getByLabelText("论坛账号"), "momen");
|
await fireEvent.update(screen.getByLabelText("论坛账号"), " momen ");
|
||||||
await fireEvent.update(screen.getByLabelText("论坛密码"), "secret");
|
await fireEvent.update(screen.getByLabelText("论坛密码"), " secret ");
|
||||||
await fireEvent.click(screen.getByRole("button", { name: "登录" }));
|
await fireEvent.click(screen.getByRole("button", { name: "登录" }));
|
||||||
await fireEvent.click(screen.getByRole("button", { name: "注册账号" }));
|
await fireEvent.click(screen.getByRole("button", { name: "注册账号" }));
|
||||||
|
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ const password = ref("");
|
|||||||
const submitLogin = () => {
|
const submitLogin = () => {
|
||||||
emit("login", {
|
emit("login", {
|
||||||
identification: identification.value.trim(),
|
identification: identification.value.trim(),
|
||||||
password: password.value,
|
password: password.value.trim(),
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user