Skip to content

Commit 165d51c

Browse files
authored
fix: tests for spanish & bump version (#74)
2 parents 9b564f3 + 69a8ec6 commit 165d51c

9 files changed

Lines changed: 29 additions & 1 deletion

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [2.4.0] - 2025-10-15
9+
10+
### Added
11+
- Support of Spanish language
12+
813
## [2.3.0] - 2025-08-05
914

1015
### Added

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "wfrp-sheet",
3-
"version": "2.3.0",
3+
"version": "2.4.0",
44
"description": "Online character sheet for Warhammer Fantasy Role Play TTRPG",
55
"type": "module",
66
"repository": {

tests/home.spec.cjs

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,3 +94,26 @@ test('link to character sheet in polish', async ({ page }) => {
9494
// Expects the URL to contain /pl/.
9595
await expect(page).toHaveURL('./wfrp-sheet/pl/');
9696
});
97+
98+
test("link to character sheet in spanish", async ({ page }) => {
99+
await page.goto("./wfrp-sheet/");
100+
101+
// Click on the polish tab
102+
const tab = await page.getByRole("link", { name: "Versión española" });
103+
await tab.click();
104+
105+
await page.evaluate(() => document.fonts.ready);
106+
107+
// Expects the tab to be active now
108+
await expect(tab).toHaveClass(/active/);
109+
// Home in polish
110+
await expect(page.locator(".wrapper")).toHaveScreenshot("home-es.png", {
111+
fullPage: true,
112+
});
113+
114+
// Click the polish sheet link.
115+
await page.getByRole("link", { name: "Ver Hoja de personaje" }).click();
116+
117+
// Expects the URL to contain /pl/.
118+
await expect(page).toHaveURL("./wfrp-sheet/es/");
119+
});
127 KB
Loading
135 KB
Loading
134 KB
Loading
4.39 KB
Loading
3.78 KB
Loading
4.2 KB
Loading

0 commit comments

Comments
 (0)