Skip to content

Conversation

@mattico
Copy link
Contributor

@mattico mattico commented Jul 25, 2018

Fixes #724

@mattico mattico merged commit b4e15e5 into rust-lang:master Jul 25, 2018
@mattico mattico deleted the fix-mdbook-test branch July 25, 2018 17:56
Ruin0x11 pushed a commit to Ruin0x11/mdBook that referenced this pull request Aug 30, 2020
ehuss added a commit to ehuss/mdBook that referenced this pull request Dec 10, 2025
This fixes a problem where custom preprocessors were not being
registered when running tests. This was caused by the test function
rebuilding the preprocessor map.

This removes the code that was rebuilding the preprocessors and removing
the IndexPreprocessor when running tests. Skipping IndexPreprocessor was
added back in rust-lang#741 to fix
rust-lang#724 which was caused by
rust-lang#685 which added the
IndexPreprocessor.

Additionally, rust-lang#1986 added
running *all* preprocessors.

The IndexPreprocessor was removed because in the past the code was
testing against the source directly, and the path from `chapter.path` is
the converted `index.md` file, and that filename does not exist in the
source. This isn't a problem anymore because due to
rust-lang#891 it is not reading from the
`src` directory.

Note that this results in a minor change where the chapter path changes
from `README.md` to `index.md` in the output and the `--chapter` option.
I think I'm ok with that change, though it would be easy to switch it
back if that's an issue.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant