- Add patch support-python-314.patch: * Support Python 3.14 normalizing. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-rnginline?expand=0&rev=14
22 lines
754 B
Diff
22 lines
754 B
Diff
Index: rnginline-1.0.0/rnginline/test/test_urlhandlers.py
|
|
===================================================================
|
|
--- rnginline-1.0.0.orig/rnginline/test/test_urlhandlers.py
|
|
+++ rnginline-1.0.0/rnginline/test/test_urlhandlers.py
|
|
@@ -1,6 +1,7 @@
|
|
from __future__ import annotations
|
|
|
|
import os
|
|
+import sys
|
|
import tempfile
|
|
from urllib import parse
|
|
|
|
@@ -32,6 +33,8 @@ def test_ensure_parsed() -> None:
|
|
def test_file_url_roundtrip(
|
|
path: str, abs: bool | None, expected_url: str, expected_path: str
|
|
) -> None:
|
|
+ if sys.version_info[:2] >= (3, 14) and expected_url.startswith('/some'):
|
|
+ expected_url = f"//{expected_url}"
|
|
kwargs = {"abs": abs} if abs is not None else {}
|
|
result_url = file.makeurl(path, **kwargs)
|
|
|