File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 1
1
import base64
2
2
import json
3
3
import os
4
+ import re
4
5
import tempfile
5
6
from pathlib import Path
6
7
@@ -618,7 +619,7 @@ def test_client_create_from_library(httpserver: HTTPServer):
618
619
619
620
620
621
def test_client_create_blob (httpserver : HTTPServer ):
621
- httpserver .expect_ordered_request (PrefixPattern ( ' /api/blobs/' ), method = 'POST' ).respond_with_response (Response (status = 201 ))
622
+ httpserver .expect_ordered_request (re . compile ( '^ /api/blobs/sha256[:-][0-9a-fA-F]{64}$ ' ), method = 'POST' ).respond_with_response (Response (status = 201 ))
622
623
623
624
client = Client (httpserver .url_for ('/' ))
624
625
@@ -1009,7 +1010,7 @@ async def test_async_client_create_from_library(httpserver: HTTPServer):
1009
1010
1010
1011
@pytest .mark .asyncio
1011
1012
async def test_async_client_create_blob (httpserver : HTTPServer ):
1012
- httpserver .expect_ordered_request (PrefixPattern ( ' /api/blobs/' ), method = 'POST' ).respond_with_response (Response (status = 201 ))
1013
+ httpserver .expect_ordered_request (re . compile ( '^ /api/blobs/sha256[:-][0-9a-fA-F]{64}$ ' ), method = 'POST' ).respond_with_response (Response (status = 201 ))
1013
1014
1014
1015
client = AsyncClient (httpserver .url_for ('/' ))
1015
1016
You can’t perform that action at this time.
0 commit comments