This commit is contained in:
parent
b8d1829bc7
commit
d359fd0a35
25 changed files with 1340 additions and 1023 deletions
|
|
@ -13,6 +13,7 @@ test("vite entrypoint loads the react application", async () => {
|
|||
test("react application defines the expected local toolbox primitives", async () => {
|
||||
const source = await readFile("website/src/main.jsx", "utf8");
|
||||
const styles = await readFile("website/src/styles/main.scss", "utf8");
|
||||
const styleNebula = await readFile("website/src/styles/_nebula.scss", "utf8");
|
||||
const styleTokens = await readFile("website/src/styles/_tokens.scss", "utf8");
|
||||
const styleBase = await readFile("website/src/styles/_base.scss", "utf8");
|
||||
const styleHome = await readFile("website/src/styles/_home.scss", "utf8");
|
||||
|
|
@ -40,10 +41,13 @@ test("react application defines the expected local toolbox primitives", async ()
|
|||
assert.match(source, /sokkog:game-toolbox-links/);
|
||||
assert.match(source, /styles\/main\.scss/);
|
||||
assert.match(styles, /@use "tokens"/);
|
||||
assert.match(styles, /@use "nebula"/);
|
||||
assert.match(styles, /@use "toolboxes"/);
|
||||
assert.match(styles, /@use "mhwilds"/);
|
||||
assert.match(styleTokens, /--gradient-brand/);
|
||||
assert.match(styleBase, /\.card-icon-button,\n\.drawer-action-button/);
|
||||
assert.match(styleNebula, /@function star-field/);
|
||||
assert.match(styleNebula, /body::after/);
|
||||
assert.match(styleBase, /\.import-icon-button/);
|
||||
assert.match(styleHome, /\.dialogue-line i/);
|
||||
assert.match(styleHome, /font-style: italic/);
|
||||
|
|
@ -54,6 +58,7 @@ test("react application defines the expected local toolbox primitives", async ()
|
|||
assert.match(styleIcons, /ui-icon-drag/);
|
||||
assert.match(styleIcons, /ui-icon-dropdown/);
|
||||
assert.match(styleIcons, /ui-icon-flip/);
|
||||
assert.match(styleIcons, /ui-icon-add/);
|
||||
assert.match(styleMhwilds, /\.mhwilds-card/);
|
||||
assert.match(styleMhwilds, /\.mhwilds-flip-indicator/);
|
||||
assert.match(styleResponsive, /@media \(max-width: 760px\)/);
|
||||
|
|
@ -160,7 +165,8 @@ test("mhwilds data and assets are available", async () => {
|
|||
assert.ok(site.toolboxes.storageHelp.items.length >= 3);
|
||||
assert.equal(games.games[0].id, "mhwilds");
|
||||
assert.equal(games.games[0].eyebrow, "Guide de jeu");
|
||||
assert.match(games.games[0].image, /mhwilds\.png/);
|
||||
assert.match(games.games[0].images.cardCover, /games\/mhwilds\/card-cover\.png/);
|
||||
assert.match(games.games[0].images.heroBg, /games\/mhwilds\/hero-bg\.png/);
|
||||
assert.ok(monsters.monsters.length > 0);
|
||||
assert.ok(endemicLife.endemicLife.length > 0);
|
||||
assert.equal(translations.monsters, "monstres");
|
||||
|
|
@ -168,6 +174,8 @@ test("mhwilds data and assets are available", async () => {
|
|||
const monsterCardSource = await readFile("website/src/features/games/mhwilds/cards/MonsterCard.jsx", "utf8");
|
||||
assert.match(monsterCardSource, /monster-card/);
|
||||
await readFile("website/public/static/img/mhwilds/chatacabra.png");
|
||||
await readFile("website/public/static/img/games/mhwilds/card-cover.png");
|
||||
await readFile("website/public/static/img/games/mhwilds/hero-bg.png");
|
||||
});
|
||||
|
||||
test("server and vite support local env configuration", async () => {
|
||||
|
|
@ -187,6 +195,7 @@ test("legacy svg icons are available for reuse", async () => {
|
|||
|
||||
assert.ok(manifest.icons.length >= 4);
|
||||
await readFile("website/public/static/icons/home.svg", "utf8");
|
||||
await readFile("website/public/static/icons/add.svg", "utf8");
|
||||
await readFile("website/public/static/icons/checklist.svg", "utf8");
|
||||
await readFile("website/public/static/icons/close.svg", "utf8");
|
||||
await readFile("website/public/static/icons/columns.svg", "utf8");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue