forked from pool/python-pymdown-extensions
- Add patch fix-toc-list-check.patch:
* Assert toc_tokens is a superset of what we are looking for. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pymdown-extensions?expand=0&rev=14
This commit is contained in:
12
fix-toc-list-check.patch
Normal file
12
fix-toc-list-check.patch
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
Index: pymdown-extensions-10.7.1/tests/test_extensions/test_smartsymbols.py
|
||||||
|
===================================================================
|
||||||
|
--- pymdown-extensions-10.7.1.orig/tests/test_extensions/test_smartsymbols.py
|
||||||
|
+++ pymdown-extensions-10.7.1/tests/test_extensions/test_smartsymbols.py
|
||||||
|
@@ -139,4 +139,6 @@ class TestSmartSymbols(util.MdCase):
|
||||||
|
|
||||||
|
md = markdown.Markdown(extensions=['toc', 'pymdownx.smartsymbols'])
|
||||||
|
md.convert('# *Foo* =/= `bar`')
|
||||||
|
- self.assertEqual(md.toc_tokens, [{'level': 1, 'id': 'foo-bar', 'name': 'Foo ≠ bar', 'children': []}])
|
||||||
|
+ contains = {'level': 1, 'id': 'foo-bar', 'name': 'Foo ≠ bar', 'children': []}
|
||||||
|
+ self.assertEqual(len(md.toc_tokens), 1)
|
||||||
|
+ self.assertLessEqual(contains.items(), md.toc_tokens[0].items())
|
@@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Mar 22 02:46:48 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com>
|
||||||
|
|
||||||
|
- Add patch fix-toc-list-check.patch:
|
||||||
|
* Assert toc_tokens is a superset of what we are looking for.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sat Mar 16 12:52:41 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
Sat Mar 16 12:52:41 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
@@ -23,6 +23,8 @@ Summary: Extension pack for Python Markdown
|
|||||||
License: MIT
|
License: MIT
|
||||||
URL: https://github.com/facelessuser/pymdown-extensions
|
URL: https://github.com/facelessuser/pymdown-extensions
|
||||||
Source: https://github.com/facelessuser/pymdown-extensions/archive/refs/tags/%{version}.tar.gz#/pymdown-extensions-%{version}.tar.gz
|
Source: https://github.com/facelessuser/pymdown-extensions/archive/refs/tags/%{version}.tar.gz#/pymdown-extensions-%{version}.tar.gz
|
||||||
|
# PATCH-FIX-OPENSUSE Assert toc_tokens is a superset of what we want to check
|
||||||
|
Patch0: fix-toc-list-check.patch
|
||||||
BuildRequires: %{python_module Markdown >= 3.2}
|
BuildRequires: %{python_module Markdown >= 3.2}
|
||||||
BuildRequires: %{python_module hatchling}
|
BuildRequires: %{python_module hatchling}
|
||||||
BuildRequires: %{python_module pip}
|
BuildRequires: %{python_module pip}
|
||||||
@@ -47,7 +49,7 @@ Covering a wide range of solutions, and while not every extension is needed
|
|||||||
by all people, there is usually at least one useful extension for anybody.
|
by all people, there is usually at least one useful extension for anybody.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n pymdown-extensions-%{version}
|
%autosetup -p1 -n pymdown-extensions-%{version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%pyproject_wheel
|
%pyproject_wheel
|
||||||
|
Reference in New Issue
Block a user