about summary refs log tree commit diff
path: root/tests/rustdoc/table-in-docblock.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/rustdoc/table-in-docblock.rs')
-rw-r--r--tests/rustdoc/table-in-docblock.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/rustdoc/table-in-docblock.rs b/tests/rustdoc/table-in-docblock.rs
new file mode 100644
index 00000000000..194f49f16d0
--- /dev/null
+++ b/tests/rustdoc/table-in-docblock.rs
@@ -0,0 +1,16 @@
+#![crate_name = "foo"]
+
+// @has foo/struct.Foo.html
+// @count - '//*[@class="docblock"]/div/table' 2
+// @!has - '//*[@class="docblock"]/table' ''
+/// | hello | hello2 |
+/// | ----- | ------ |
+/// | data  | data2  |
+pub struct Foo;
+
+impl Foo {
+    /// | hello | hello2 |
+    /// | ----- | ------ |
+    /// | data  | data2  |
+    pub fn foo(&self) {}
+}