fix(webui): show language names only in their native form (#5646)
* fix(webui): show native language names only * test(webui): assert native language names positively
This commit is contained in:
1 parent
236185d4f5
commit
6c0f6bf0ee
3 files changed
+22
-18
No files matched your search
@@ -452,6 +452,17 @@ describe("webui i18n", () => {
|
||||
expect(resolveInitialLocale()).toBe("zh-CN");
|
||||
});
|
||||
|
||||
it("lists each language by its native name", async () => {
|
||||
const user = userEvent.setup();
|
||||
|
||||
render(<LanguageSwitcher />);
|
||||
await user.click(screen.getByRole("button", { name: "Change language" }));
|
||||
|
||||
for (const { nativeLabel } of supportedLocales) {
|
||||
expect(screen.getByRole("menuitemradio", { name: nativeLabel })).toBeInTheDocument();
|
||||
}
|
||||
});
|
||||
|
||||
it("switches UI copy and document locale through the language switcher", async () => {
|
||||
const user = userEvent.setup();
|
||||
|
||||
|
||||
Reference in new issue
Block a user