Skip to content

Commit aa2dba2

Browse files
docs-test
1 parent 6a58271 commit aa2dba2

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

.github/workflows/build-book.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
run: python3 -m pip install nox
4343

4444
- name: Build book
45-
run: nox -s docs
45+
run: nox -s docs-test
4646

4747
# Save html as artifact
4848
- name: Save book html as artifact for viewing

noxfile.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,17 @@ def docs(session):
1616
cmd.extend(build_command + session.posargs)
1717
session.run(*cmd)
1818

19+
@nox.session(name="docs-test")
20+
def docs_test(session):
21+
"""
22+
Same as `docs`, but rebuild everything and fail on warnings for testing
23+
"""
24+
session.install("-r", "requirements.txt")
25+
cmd = ["sphinx-build"]
26+
cmd.extend(['-W', '--keep-going', '-E', '-a'])
27+
cmd.extend(build_command + session.posargs)
28+
session.run(*cmd)
29+
1930

2031
@nox.session(name="docs-live")
2132
def docs_live(session):

0 commit comments

Comments
 (0)