summary refs log tree commit diff
path: root/src/test/rustdoc-ui
AgeCommit message (Collapse)AuthorLines
2020-07-13Rollup merge of #74147 - dennis-hamester:fix/issue-74134, r=jyn514Manish Goregaokar-0/+51
rustdoc: Allow linking from private items to private types Fixes #74134 After PR #72771 this would trigger an intra_doc_link_resolution_failure warning when rustdoc is invoked without --document-private-items. Links from private items to private types are however never actually generated in that case and thus shouldn't produce a warning. These links are in fact a very useful tool to document crate internals. Tests are added for all 4 combinations of public/private items and link targets. Test 1 is the case mentioned above and fails without this commit. Tests 2 - 4 passed before already but are added nonetheless to prevent regressions.
2020-07-11test: rustdoc-ui: issue-74134: Shorten a too long lineDennis Hamester-1/+1
2020-07-11test: rustdoc-ui: Expand issue-74134 to cover types in a private moduleDennis Hamester-0/+15
2020-07-11test: rustdoc-ui: Add issue-74134, replacing test/rustdoc/issue-74134-*Dennis Hamester-0/+36
As per the discussion in PR #74147, the 4 individual tests are replaced by a single one. The test is expanded to cover all 4 public/private cases, each with and without --document-private-items.
2020-07-07rustdoc: Rename invalid_codeblock_attribute lint to be pluralOliver Middleton-6/+6
2020-06-26Generate docs for links to private items when passed --document-privateJoshua Nelson-0/+36
- Pass around document_private a lot more - Add tests + Add tests for intra-doc links to private items + Add ignored tests for warnings in reference links
2020-06-23Rollup merge of #72780 - GuillaumeGomez:enforce-doc-alias-check, r=ollie27Manish Goregaokar-0/+29
Enforce doc alias check Part of #50146. r? @ollie27
2020-06-21Update UI testsGuillaume Gomez-2/+4
2020-05-30Add test for doc alias attribute validationGuillaume Gomez-0/+29
2020-05-15remove extra space from crate-level doctest namesAndy Russell-0/+22
2020-04-24Add rustdoc regression test for the unused_braces lintflip1995-0/+14
2020-04-23Rollup merge of #71408 - GuillaumeGomez:check-code-blocks-tags, r=kinnisonDylan DPC-0/+493
Check code blocks tags Fixes #71347. Explanations here: I realized recently that it was a common issue to confuse/misspell tags on code blocks. This is actually quite a big issue since it generally ends up in a code blocks being ignored since it's not being considered as a rust one. With this new warning, users will at least be notified about it. PS: some improvements can be done on the error rendering but considering how big the PR already is, I think it's better to do it afterwards. r? @ollie27 cc @rust-lang/rustdoc
2020-04-23Add UI tests for new rustdoc lintGuillaume Gomez-0/+493
2020-04-19Moving all rustdoc-ui tests to check-passVal Markovic-19/+19
These were all build-pass before and don't seem to need it. Helps with #62277
2020-04-11rustc: Add a warning count upon completionRoccoDev-0/+8
2020-03-28Auto merge of #66938 - GuillaumeGomez:lint-for-no-crate-level-doc, r=Dylan-DPCbors-0/+15
Add lint when no doc is present at the crate-level Follow-up of #66267. r? @kinnison
2020-03-22fix one more testmark-1/+1
2020-03-22Update lint name to follow conventionGuillaume Gomez-3/+3
2020-03-22Update testsGuillaume Gomez-8/+7
2020-03-22Add lint when no doc is present at the crate-levelGuillaume Gomez-0/+16
2020-03-14resolve: Fix regression in resolution of raw keywords in pathsVadim Petrochenkov-5/+5
2020-03-02remove output-format testGuillaume Gomez-10/+0
2020-03-02Replace ToJson with serdeGuillaume Gomez-8/+18
2020-03-02add tests for rustdoc output-format jsonGuillaume Gomez-0/+34
2020-02-09--bless --compare-mode=nllMatthias Prechtl-2/+2
2020-02-06rustc_macros: don't limit the -Zmacro-backtrace suggestion to extern macros.Eduard-Mihai Burtescu-0/+1
2020-01-24Normalise notes with the/isvarkor-13/+13
2020-01-20Rollup merge of #68357 - ollie27:rustdoc_test_errors, r=GuillaumeGomezDylan DPC-0/+62
rustdoc: Fix handling of compile errors when running `rustdoc --test` * Call `abort_if_errors` so all errors actually stop rustdoc. * Don't panic with "compiler aborted in rustdoc!", instead just exit to avoid the ugly panic message. * Use rlib as the crate type when searching for doctests matching what is used for doc generation so `#[no_std]` crates don't create "no global memory allocator" errors. Fixes #52243 Fixes #54010 r? @GuillaumeGomez
2020-01-18rustdoc: Fix handling of compile errors when running `rustdoc --test`Oliver Middleton-0/+62
* Call `abort_if_errors` so all errors actually stop rustdoc. * Don't panic with "compiler aborted in rustdoc!", instead just exit to avoid the ugly panic message. * Use rlib as the crate type when searching for doctests matching what is used for doc generation so `#[no_std]` crates don't create "no global memory allocator" errors.
2020-01-17rustdoc: Catch fatal errors when syntax highlightingOliver Middleton-0/+21
For some errors the lexer will unwind so we need to handle that in addition to handling `token::Unknown`.
2020-01-12Update `output-default.json` and rustdoc testvarkor-1/+1
2020-01-04buffer lexer errors in rustdoc syntax checkingAndy Russell-109/+19
2019-12-04rustdoc: Add test for fixed issueOliver Middleton-0/+15
2019-11-27Auto merge of #66675 - GuillaumeGomez:support-anchors-intra-doc-links, ↵bors-28/+105
r=kinnison Support anchors intra doc links Fixes #62833 Part of #43466. cc @ollie27 r? @kinnison
2019-11-26Rollup merge of #66754 - estebank:rustdoc-capitalization, r=Dylan-DPCTyler Mandry-16/+16
Various tweaks to diagnostic output
2019-11-25Update error messagesGuillaume Gomez-36/+36
2019-11-24Fix some rustdoc error capitalizationEsteban Küber-16/+16
2019-11-23Add test for anchorsGuillaume Gomez-0/+77
2019-11-21Point at type in `let` assignment on type errorsEsteban Küber-1/+3
2019-11-18Surround types with backticks in type errorsEsteban Küber-1/+1
2019-11-18Remove E0308 note when primary label has all infoEsteban Küber-3/+0
2019-11-13Rollup merge of #66166 - GuillaumeGomez:rename-rustdoc-to-doc, r=QuietMisdreavusYuki Okushi-3/+3
rename cfg(rustdoc) into cfg(doc) Needed by https://github.com/rust-lang/rust/pull/61351 r? @QuietMisdreavus
2019-11-10Add warning annotations to rustdoc-ui testsTomasz Miąsko-46/+67
2019-11-06rename cfg(rustdoc) into cfg(doc)Guillaume Gomez-3/+3
2019-11-03use silent emitter for rustdoc highlighting passAndy Russell-64/+0
2019-10-29stabilize cfg(doctest)Guillaume Gomez-4/+2
2019-10-24Increase spacing for suggestions in diagnosticsEsteban Küber-0/+15
Make the spacing between the code snippet and verbose structured suggestions consistent with note and help messages.
2019-10-21Rollup merge of #65314 - tmiasko:rustdoc-z, r=ollie27Mazdak Farrokhzad-15/+15
rustdoc: forward -Z options to rustc Currently rustdoc does not forward `-Z` options to rustc when building test executables. This makes impossible to use rustdoc to run test samples when crate under test is instrumented with one of sanitizers `-Zsanitizer=...`, since the final linking step will not include sanitizer runtime library. Forward `-Z` options to rustc to solve the issue. Helps with #43031.
2019-10-11rustdoc: forward -Z options to rustcTomasz Miąsko-15/+15
Currently rustdoc does not forward `-Z` options to rustc when building test executables. This makes impossible to use rustdoc to run test samples when crate under test is instrumented with one of sanitizers `-Zsanitizer=...`, since the final linking step will not include sanitizer runtime library. Forward `-Z` options to rustc to solve the issue. Helps with #43031.
2019-10-10Add and update rustdoc ui testGuillaume Gomez-2/+24