Skip to content

Commit a97e803

Browse files
committed
test - test that serif and simple default to heading color being body color
1 parent f8a9a3c commit a97e803

File tree

6 files changed

+48
-1
lines changed

6 files changed

+48
-1
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/.quarto/
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
project:
2+
type: default
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
/*-- scss:defaults --*/
2+
3+
$body-color: #000080;
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
title: "Quarto Title Test"
3+
format: revealjs
4+
theme: [simple, custom.scss]
5+
---
6+
7+
## slide 1
8+
9+
Text for slide 1
10+
11+
## side 2
12+
13+
Text for slide 2
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
title: "Quarto Title Test"
3+
format: revealjs
4+
theme: [simple, custom.scss]
5+
---
6+
7+
## slide 1
8+
9+
Text for slide 1
10+
11+
## side 2
12+
13+
Text for slide 2

tests/integration/playwright/tests/revealjs-themes.spec.ts

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,4 +78,19 @@ test('Callout title color in dracula theme is correctly tweaked to use same as b
7878
const calloutTitleLoc = page.getByText('Title of the callout', { exact: true });
7979
const calloutContentLoc = page.getByText('Content', { exact: true });
8080
await checkColorIdentical(calloutTitleLoc, calloutContentLoc, 'color');
81-
});
81+
});
82+
83+
test('Headings color in simple and serif theme are correctly defaulting to $body-bg', async ({ page }) => {
84+
await page.goto('./revealjs/heading-color/simple.html#/slide-1');
85+
await checkColorIdentical(
86+
page.getByText('Text for slide 1', { exact: true }),
87+
page.getByRole('heading', { name: 'slide' }),
88+
'color'
89+
);
90+
await page.goto('./revealjs/heading-color/serif.html#/slide-1');
91+
await checkColorIdentical(
92+
page.getByText('Text for slide 1', { exact: true }),
93+
page.getByRole('heading', { name: 'slide' }),
94+
'color'
95+
);
96+
});

0 commit comments

Comments
 (0)