Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure permalinks and ankorlinks are not restricted by toc_depth #1108

Merged
merged 2 commits into from Feb 24, 2021

Conversation

waylan
Copy link
Member

@waylan waylan commented Feb 24, 2021

This fixes a regression which was introduced with support for toc_depth.
Relevant tests have been moved and updated to the new framework.
Fixes #1107.

The test framework also received an addition. The assertMarkdownRenders
method now accepts a new keyword expected_attrs which consists of a dict
of attrs and expected values. Each is checked against the attr of the
Markdown instance. This was needed to check the value of md.toc and
md.toc_tokens in some of the included tests.

This fixes a regression which was introduced with support for toc_depth.
Relevant tests have been moved and updated to the new framework.
Fixes Python-Markdown#1107.

The test fraamework also received an addition. The assertMarkdownRenders
method now accepts a new keyword expected_attrs which consists of a dict
of attrs and expected values. Each is checked against the attr of the
Markdown instance. This was needed to check the value of md.toc and
md.toc_tokens in some of the included tests.
@waylan waylan merged commit 613ad50 into Python-Markdown:master Feb 24, 2021
@waylan waylan deleted the 1107 branch February 24, 2021 19:20
Phuker added a commit to Phuker/md2html that referenced this pull request Aug 26, 2021
Note:
Python-Markdown, 2021-2-24, version 3.3.4 changes:
Ensure permalinks and ankorlinks are not restricted by toc_depth
Python-Markdown/markdown#1108
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.

TOC: Include permalink for headers out of toc_depth range
1 participant