Skip to content

Commit

Permalink
[formrecognizer] test parity with other languages (#12059)
Browse files Browse the repository at this point in the history
* add encoding check test

* add copy test bad model id

* test big endian tiff

* add missing blank page test for custom forms

* update tests to use GlobalClientPreparer
  • Loading branch information
kristapratico authored Jun 17, 2020
1 parent 83bf9a5 commit 99799d5
Show file tree
Hide file tree
Showing 27 changed files with 4,615 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
interactions:
- request:
body: 'b''{"source": "https://fakeuri.com/blank%20space"}'''
headers:
Accept:
- '*/*'
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Length:
- '47'
Content-Type:
- application/json
User-Agent:
- azsdk-python-ai-formrecognizer/1.0.0b4 Python/3.7.3 (Windows-10-10.0.18362-SP0)
Python/3.7.3 (Windows-10-10.0.18362-SP0)
method: POST
uri: https://centraluseuap.api.cognitive.microsoft.com/formrecognizer/v2.0-preview/layout/analyze
response:
body:
string: '{"error": {"code": "FailedToDownloadImage", "message": "Failed to download
image from input URL."}}'
headers:
apim-request-id:
- 0801fae5-b315-4d33-9df7-c6fb8333d4db
content-type:
- application/json; charset=utf-8
date:
- Mon, 15 Jun 2020 18:08:28 GMT
strict-transport-security:
- max-age=31536000; includeSubDomains; preload
transfer-encoding:
- chunked
x-content-type-options:
- nosniff
x-envoy-upstream-service-time:
- '2496'
status:
code: 400
message: Bad Request
version: 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
interactions:
- request:
body: 'b''{"source": "https://fakeuri.com/blank%20space"}'''
headers:
Content-Length:
- '47'
Content-Type:
- application/json
User-Agent:
- azsdk-python-ai-formrecognizer/1.0.0b4 Python/3.7.3 (Windows-10-10.0.18362-SP0)
Python/3.7.3 (Windows-10-10.0.18362-SP0)
method: POST
uri: https://centraluseuap.api.cognitive.microsoft.com/formrecognizer/v2.0-preview/layout/analyze
response:
body:
string: '{"error": {"code": "FailedToDownloadImage", "message": "Failed to download
image from input URL."}}'
headers:
apim-request-id: ba66c94f-af17-4785-a6d6-7c04ca117d87
content-type: application/json; charset=utf-8
date: Mon, 15 Jun 2020 18:18:10 GMT
strict-transport-security: max-age=31536000; includeSubDomains; preload
transfer-encoding: chunked
x-content-type-options: nosniff
x-envoy-upstream-service-time: '490'
status:
code: 400
message: Bad Request
url: https://centraluseuap.api.cognitive.microsoft.com//formrecognizer/v2.0-preview/layout/analyze
version: 1
Loading

0 comments on commit 99799d5

Please sign in to comment.