Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support client certificates #31529

Merged

Conversation

mxschmitt
Copy link
Member

@mxschmitt mxschmitt commented Jul 3, 2024

This comment has been minimized.

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from e64d5f9 to 24339b5 Compare July 3, 2024 10:21

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from 24339b5 to 0a3d5dd Compare July 4, 2024 09:07

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from 0a3d5dd to 8723c6c Compare July 4, 2024 09:42

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from 8723c6c to 5521b11 Compare July 5, 2024 15:15
@mxschmitt mxschmitt marked this pull request as ready for review July 5, 2024 15:28

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from 94ad52d to e3ef568 Compare July 10, 2024 07:49

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from f6b1532 to cb787be Compare July 10, 2024 20:43

This comment has been minimized.

This comment has been minimized.

@Az8th
Copy link
Contributor

Az8th commented Jul 11, 2024

Thanks a lot for adding this feature, it is greatly appreciated :D

@@ -190,9 +193,11 @@ export abstract class APIRequestContext extends SdkObject {
maxRedirects: params.maxRedirects === 0 ? -1 : params.maxRedirects === undefined ? 20 : params.maxRedirects,
timeout,
deadline,
...(process.env.PW_DO_NOT_USE_EXTRA_CA_CERTS ? { ca: [fs.readFileSync(process.env.PW_DO_NOT_USE_EXTRA_CA_CERTS)] } : {}),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • nit: I'd add an if statement at line 199.5 instead.
  • Should it be PWTEST_CUSTOM_CA? It confusing has "do not use" in the env name, and then uses the ca.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to make the name clear that this is unsupported. Changed it to UNSUPPORTED instead.

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from c62b928 to 560f06b Compare July 11, 2024 21:40

This comment has been minimized.

mxschmitt and others added 2 commits July 12, 2024 10:15
Co-authored-by: Dmitry Gozman <[email protected]>
Signed-off-by: Max Schmitt <[email protected]>

This comment has been minimized.

This comment has been minimized.

@mxschmitt mxschmitt force-pushed the client-certificates-api-request-context branch from 550c500 to 37ab55c Compare July 12, 2024 08:29

This comment has been minimized.

This comment has been minimized.

Copy link
Contributor

Test results for "tests 1"

1 failed
❌ [installation tests] › playwright-electron-should-work.spec.ts:31:5 › electron should work with special characters in path

7 flaky ⚠️ [chromium-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture
⚠️ [chromium-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture
⚠️ [chromium-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture
⚠️ [firefox-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture
⚠️ [chromium-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture
⚠️ [playwright-test] › ui-mode-test-screencast.spec.ts:21:5 › should show screenshots
⚠️ [webkit-library] › library/browsercontext-fetch-happy-eyeballs.spec.ts:49:3 › get should work on request fixture

28905 passed, 708 skipped
✔️✔️✔️

Merge workflow run.

@mxschmitt mxschmitt merged commit 9569cb5 into microsoft:main Jul 12, 2024
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants