Skip to content

Commit 6302389

Browse files
committed
fix(playwright): fix papersize argument
1 parent 6a70de6 commit 6302389

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Event payload body.
2222
| **document_url** | url | Fetch the html content from `document_url` to disk before rendering. |
2323
| **browser_url** | url | Browser the `browser_url` with `playwright` before rendering with `renderer` |
2424
| **browser_headers** | Mapping[str,str] | Add additional headers to playwright before visiting `browser_url` |
25-
| **browser_papersize** | `A4` or `letter` | Size of the page when creating PDF with playwright | |
25+
| **browser_papersize** | `A4` or `Letter` | Size of the page when creating PDF with playwright | |
2626
| **renderer** | `princexml` or `playwright` | Renderer to render the html with |
2727
| **bucket_name** | string | Output the resulting pdf to `s3://{bucket_name}/{uuid}.pdf`. The lambda will require permission to upload to the bucket. The response will include `bucket`, `key`, `presigned_url` |
2828
| **presigned_url** | url | Output the resulting pdf to the presigned url. Generate the presigned url with `put_object`. See Output for more information. |

lambda_function.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class Renderers(str, enum.Enum):
4141

4242
class Papersize(str, enum.Enum):
4343
A4 = "A4"
44-
Letter = "letter"
44+
Letter = "Letter"
4545

4646

4747
class Payload(pydantic.BaseModel):

tests/test_lambda_e2e.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def test_check_license_returns_a_license_payload() -> None:
5454

5555

5656
@pytest.mark.parametrize("renderer", ["princexml", "playwright"])
57-
@pytest.mark.parametrize("browser_papersize", ["A4", "letter"])
57+
@pytest.mark.parametrize("browser_papersize", ["A4", "Letter"])
5858
class TestRenderers:
5959
def test_generating_pdf_from_document_url(self, renderer: str, browser_papersize: str):
6060
s3_client = get_s3_client()

0 commit comments

Comments
 (0)