File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 24
24
SIMPLE_QUERY = {str (i ): str (i ) for i in range (10 )}
25
25
SIMPLE_INT_QUERY = {str (i ): i for i in range (10 )}
26
26
QUERY_STRING = "x=y&z=1"
27
+ URL_VERY_LONG_PATH = URL ("http://www.domain.tld/" + "req/" * 100 )
28
+ URL_LONG_PATH = URL ("http://www.domain.tld/" + "req/" * 30 )
27
29
28
30
29
31
class _SubClassedStr (str ):
@@ -594,6 +596,13 @@ def _run() -> None:
594
596
URL_WITH_LONGER_PATH - URL_WITH_PATH
595
597
596
598
599
+ def test_url_subtract_long_urls (benchmark : BenchmarkFixture ) -> None :
600
+ @benchmark
601
+ def _run () -> None :
602
+ for _ in range (100 ):
603
+ URL_VERY_LONG_PATH - URL_LONG_PATH
604
+
605
+
597
606
def test_url_host_port_subcomponent (benchmark : BenchmarkFixture ) -> None :
598
607
cache_non_default = URL_WITH_NOT_DEFAULT_PORT ._cache
599
608
cache = BASE_URL ._cache
You can’t perform that action at this time.
0 commit comments