Skip to content

SDKS-4193: Protect collector e2e tests #346

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ancheetah
Copy link
Collaborator

JIRA Ticket

https://pingidentity.atlassian.net/browse/SDKS-4193

Description

  • Adds e2e test for Protect collector with Custom HTML Form
  • Adds e2e test for Protect collector with P1 Form

No changeset

Copy link

changeset-bot bot commented Jul 10, 2025

⚠️ No Changeset found

Latest commit: e85fc69

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

nx-cloud bot commented Jul 10, 2025

View your CI Pipeline Execution ↗ for commit e85fc69

Command Status Duration Result
nx run-many -t build ✅ Succeeded 1s View ↗
nx affected -t build typecheck lint test e2e-ci ✅ Succeeded 1m 33s View ↗
nx-cloud record -- nx format:check ✅ Succeeded 1s View ↗

☁️ Nx Cloud last updated this comment at 2025-07-16 20:22:58 UTC

Copy link
Contributor

github-actions bot commented Jul 10, 2025

Deployed b2c7ef8 to https://ForgeRock.github.io/ping-javascript-sdk/pr-346/b2c7ef83fb942e3759a195edadb1b634031018fe branch gh-pages in ForgeRock/ping-javascript-sdk

Copy link
Contributor

github-actions bot commented Jul 10, 2025

📦 Bundle Size Analysis

📦 Bundle Size Analysis

➖ No Changes

@pingidentity/protect - 108.3 KB
@forgerock/device-client - 9.2 KB
@forgerock/davinci-client - 34.3 KB
@forgerock/sdk-types - 5.6 KB
@forgerock/sdk-utilities - 4.0 KB
@forgerock/sdk-oidc - 3.4 KB
@forgerock/sdk-request-middleware - 4.2 KB
@forgerock/storage - 1.3 KB
@forgerock/sdk-logger - 1.6 KB
@forgerock/iframe-manager - 2.5 KB
@forgerock/oidc-client - 1.2 KB


11 packages analyzed • Baseline from latest main build

Legend

🆕 New package
🔺 Size increased
🔻 Size decreased
➖ No change

ℹ️ How bundle sizes are calculated
  • Current Size: Total gzipped size of all files in the package's dist directory
  • Baseline: Comparison against the latest build from the main branch
  • Files included: All build outputs except source maps and TypeScript build cache
  • Exclusions: .map, .tsbuildinfo, and .d.ts.map files

🔄 Updated automatically on each push to this PR

@ancheetah ancheetah requested review from cerebrl and ryanbas21 July 10, 2025 14:55
Copy link
Collaborator

@cerebrl cerebrl left a comment

Choose a reason for hiding this comment

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

Other than my one comment, which applies to both tests, this looks great.


await page.getByRole('button', { name: 'Sign On' }).click();

await expect(
Copy link
Collaborator

Choose a reason for hiding this comment

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

My only complaint about this single test is that we not entirely sure a proper payload was sent to the server. Maybe the server failed because of missing payload? Should we add a assertion that tests that we sent a payload that has predictable attributes, like length of string or the start of the string always has some combination of characters?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good call. The SDK should actually error before data is sent to the server if the protect payload is missing or not a string. This would be a good way to test that. Will add something that checks if the string starts with R/o.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Updated

@ancheetah ancheetah force-pushed the SDKS-4193-protect-dv-e2e branch from ffa41b1 to e85fc69 Compare July 16, 2025 20:20
@ancheetah ancheetah requested a review from cerebrl July 16, 2025 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants