Skip to content

Commit

Permalink
add test for rustdoc's --themes flag
Browse files Browse the repository at this point in the history
  • Loading branch information
QuietMisdreavus authored and GuillaumeGomez committed Nov 18, 2019
1 parent f3e4279 commit d350008
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/test/run-make-fulldeps/rustdoc-themes/Makefile
@@ -0,0 +1,10 @@
-include ../tools.mk

# Test that rustdoc will properly load in a theme file and display it in the theme selector.

OUTPUT_DIR := "$(TMPDIR)/rustdoc-themes"

all:
cp $(S)/src/librustdoc/html/static/themes/light.css $(TMPDIR)/test.css
$(RUSTDOC) -o $(OUTPUT_DIR) foo.rs --themes $(TMPDIR)/test.css
$(HTMLDOCCK) $(OUTPUT_DIR) foo.rs
4 changes: 4 additions & 0 deletions src/test/run-make-fulldeps/rustdoc-themes/foo.rs
@@ -0,0 +1,4 @@
// @has test.css
// @has foo/struct.Foo.html
// @has - '//link[@rel="stylesheet"]/@href' '../test.css'
pub struct Foo;

0 comments on commit d350008

Please sign in to comment.