about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume1.gomez@gmail.com>2021-04-14 00:52:35 +0200
committerGuillaume Gomez <guillaume.gomez@huawei.com>2021-08-05 23:08:28 +0200
commit89bdc33781b36f6822c0c499fc9d15c41815103f (patch)
treeaf9a1b8f067b4a2c50bca37527b40b35adda52a0
parent1abb7faddb406d5b40ecca39a6395957ccf9c778 (diff)
downloadrust-89bdc33781b36f6822c0c499fc9d15c41815103f.tar.gz
rust-89bdc33781b36f6822c0c499fc9d15c41815103f.zip
Update rustdoc tests
-rw-r--r--src/librustdoc/html/highlight/fixtures/sample.html2
-rw-r--r--src/librustdoc/html/highlight/tests.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/librustdoc/html/highlight/fixtures/sample.html b/src/librustdoc/html/highlight/fixtures/sample.html
index 8d23477bbcb..866caea9256 100644
--- a/src/librustdoc/html/highlight/fixtures/sample.html
+++ b/src/librustdoc/html/highlight/fixtures/sample.html
@@ -23,7 +23,7 @@
     <span class="macro">assert!</span>(<span class="self">self</span>.<span class="ident">length</span> <span class="op">&lt;</span> <span class="ident">N</span> <span class="op">&amp;&amp;</span> <span class="ident">index</span> <span class="op">&lt;</span><span class="op">=</span> <span class="self">self</span>.<span class="ident">length</span>);
     <span class="ident">::std::env::var</span>(<span class="string">&quot;gateau&quot;</span>).<span class="ident">is_ok</span>();
     <span class="attribute">#[<span class="ident">rustfmt::skip</span>]</span>
-    <span class="kw">let</span> <span class="ident">s</span>:<span class="ident">std</span><span class="ident">::path::PathBuf</span> <span class="op">=</span> <span class="ident">std::path::PathBuf::new</span>();
+    <span class="kw">let</span> <span class="ident">s</span>:<span class="ident">std::path::PathBuf</span> <span class="op">=</span> <span class="ident">std::path::PathBuf::new</span>();
     <span class="kw">let</span> <span class="kw-2">mut</span> <span class="ident">s</span> <span class="op">=</span> <span class="ident">String::new</span>();
 
     <span class="kw">match</span> <span class="kw-2">&amp;</span><span class="ident">s</span> {
diff --git a/src/librustdoc/html/highlight/tests.rs b/src/librustdoc/html/highlight/tests.rs
index a505865b149..a637d8085cb 100644
--- a/src/librustdoc/html/highlight/tests.rs
+++ b/src/librustdoc/html/highlight/tests.rs
@@ -22,7 +22,7 @@ fn test_html_highlighting() {
         let src = include_str!("fixtures/sample.rs");
         let html = {
             let mut out = Buffer::new();
-            write_code(&mut out, src, Edition::Edition2018);
+            write_code(&mut out, src, Edition::Edition2018, 0, None, "");
             format!("{}<pre><code>{}</code></pre>\n", STYLE, out.into_inner())
         };
         expect_file!["fixtures/sample.html"].assert_eq(&html);
@@ -36,7 +36,7 @@ fn test_dos_backline() {
     println!(\"foo\");\r\n\
 }\r\n";
         let mut html = Buffer::new();
-        write_code(&mut html, src, Edition::Edition2018);
+        write_code(&mut html, src, Edition::Edition2018, 0, None, "");
         expect_file!["fixtures/dos_line.html"].assert_eq(&html.into_inner());
     });
 }