Skip to content

feat(solidjs): Add e2e tests #12328

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

Merged
merged 4 commits into from
Jun 4, 2024
Merged

feat(solidjs): Add e2e tests #12328

merged 4 commits into from
Jun 4, 2024

Conversation

andreiborza
Copy link
Member

No description provided.

@andreiborza andreiborza added the Package: solid Issues related to the Sentry Solid SDK label Jun 3, 2024
},
"license": "MIT",
"devDependencies": {
"@playwright/test": "^1.43.1",
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
"@playwright/test": "^1.43.1",
"@playwright/test": "^1.44.1",

let's use latest here!

Copy link
Member

Choose a reason for hiding this comment

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

ah, and also add @sentry-internal/test-utils as a dep, explicitly.

Copy link
Member Author

Choose a reason for hiding this comment

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

Added

Co-authored-by: Francesco Novy <francesco.novy@sentry.io>
});

test('sends a navigation transaction', async ({ page }) => {
page.on('console', msg => console.log(msg.text()));
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
page.on('console', msg => console.log(msg.text()));


test('sends a navigation transaction', async ({ page }) => {
page.on('console', msg => console.log(msg.text()));
const pageloadTxnPromise = waitForTransaction('solidjs', async transactionEvent => {
Copy link
Member

Choose a reason for hiding this comment

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

Actually no need to wait on this, we can just wait for the navigation only, that should be all fine! Just go to / and then navigate, should always emit a navgiation span either way.

Copy link
Member Author

Choose a reason for hiding this comment

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

Right, removed.

// transactions with the proper name once the `useLocation` hook triggers.
page.on('console', msg => console.log(msg.text()));

const pageloadTxnPromise = waitForTransaction('solidjs', async transactionEvent => {
Copy link
Member

Choose a reason for hiding this comment

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

same here, no need to wait on pageload (we need to wait on the first navigation, to ensure that we test the correct thing afterwards)

Copy link
Member Author

Choose a reason for hiding this comment

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

Removed.

Copy link
Contributor

github-actions bot commented Jun 3, 2024

size-limit report 📦

Path Size
@sentry/browser 21.74 KB (0%)
@sentry/browser (incl. Tracing) 32.77 KB (+0.03% 🔺)
@sentry/browser (incl. Tracing, Replay) 68.34 KB (+0.02% 🔺)
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 61.65 KB (+0.02% 🔺)
@sentry/browser (incl. Tracing, Replay with Canvas) 72.41 KB (+0.02% 🔺)
@sentry/browser (incl. Tracing, Replay, Feedback) 84.5 KB (+0.02% 🔺)
@sentry/browser (incl. Tracing, Replay, Feedback, metrics) 86.36 KB (+0.02% 🔺)
@sentry/browser (incl. metrics) 25.92 KB (0%)
@sentry/browser (incl. Feedback) 37.89 KB (0%)
@sentry/browser (incl. sendFeedback) 26.32 KB (0%)
@sentry/browser (incl. FeedbackAsync) 30.86 KB (0%)
@sentry/react 24.51 KB (0%)
@sentry/react (incl. Tracing) 35.81 KB (+0.03% 🔺)
@sentry/vue 25.73 KB (0%)
@sentry/vue (incl. Tracing) 34.61 KB (+0.05% 🔺)
@sentry/svelte 21.87 KB (0%)
CDN Bundle 23.11 KB (0%)
CDN Bundle (incl. Tracing) 34.5 KB (+0.03% 🔺)
CDN Bundle (incl. Tracing, Replay) 68.43 KB (+0.02% 🔺)
CDN Bundle (incl. Tracing, Replay, Feedback) 73.6 KB (+0.02% 🔺)
CDN Bundle - uncompressed 68 KB (0%)
CDN Bundle (incl. Tracing) - uncompressed 102.18 KB (+0.02% 🔺)
CDN Bundle (incl. Tracing, Replay) - uncompressed 212.07 KB (+0.01% 🔺)
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 224.54 KB (+0.01% 🔺)
@sentry/nextjs (client) 35.16 KB (+0.04% 🔺)
@sentry/sveltekit (client) 33.4 KB (+0.04% 🔺)
@sentry/node 115.24 KB (0%)
@sentry/aws-serverless 103.73 KB (+0.01% 🔺)

@andreiborza andreiborza requested a review from mydea June 4, 2024 07:31
Copy link
Member

@mydea mydea left a comment

Choose a reason for hiding this comment

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

sweet!

@andreiborza andreiborza merged commit 136575c into develop Jun 4, 2024
110 checks passed
@andreiborza andreiborza deleted the ab/solidjs-e2e-tests branch June 4, 2024 07:53
billyvg pushed a commit that referenced this pull request Jun 10, 2024
Co-authored-by: Francesco Novy <francesco.novy@sentry.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: solid Issues related to the Sentry Solid SDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants