Skip to content

Commit 2f564cb

Browse files
committed
Add one more tests about sidebar
Related to #8869
1 parent d486bed commit 2f564cb

File tree

4 files changed

+51
-0
lines changed

4 files changed

+51
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/.quarto/
2+
_site
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
project:
2+
type: website
3+
4+
website:
5+
title: "Test"
6+
7+
navbar:
8+
left:
9+
- href: index.qmd
10+
text: Home
11+
12+
sidebar:
13+
title: "Contents"
14+
contents:
15+
- section: About
16+
contents:
17+
- href: about.qmd
18+
text: About
19+
20+
format:
21+
html: default
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
title: "About page"
3+
_quarto:
4+
tests:
5+
html:
6+
ensureHtmlElements:
7+
-
8+
- 'nav.navbar li.nav-item a.nav-link'
9+
- 'nav#quarto-sidebar li.sidebar-item a.sidebar-link span.menu-text'
10+
- 'nav#quarto-sidebar li.sidebar-item ul.sidebar-section'
11+
- []
12+
---
13+
14+
This is an about page that should also have a sidebar
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
title: "Sidebar-title"
3+
_quarto:
4+
tests:
5+
html:
6+
ensureHtmlElements:
7+
-
8+
- 'nav.navbar li.nav-item a.nav-link'
9+
- 'nav#quarto-sidebar li.sidebar-item a.sidebar-link span.menu-text'
10+
- 'nav#quarto-sidebar li.sidebar-item ul.sidebar-section'
11+
- []
12+
---
13+
14+
This test covers https://github.com/quarto-dev/quarto-cli/discussions/8869

0 commit comments

Comments
 (0)