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

Task: Implement additional Jetpack tests. #80730

Closed
35 of 38 tasks
worldomonation opened this issue Aug 17, 2023 · 11 comments
Closed
35 of 38 tasks

Task: Implement additional Jetpack tests. #80730

worldomonation opened this issue Aug 17, 2023 · 11 comments
Assignees

Comments

@worldomonation
Copy link
Contributor

worldomonation commented Aug 17, 2023

Details

Taking into account outcome for pdWQjU-rL-p2, begin implementing new Jetpack E2E tests from the highest priority & easiest to implement.

Checklist

Task list taken from the Jetpack - Calypso test coverage mapping spreadsheet.

No response

Must Cover Tasks

Important Tasks

@dpasque
Copy link
Contributor

dpasque commented Aug 22, 2023

I'll take point on Forms. Asked a question below about designing a potential dedicated E2E spec (as opposed to block smoke test) that focuses on Forms. Let me know what you think!

pdWQjU-rL-p2#comment-537

@dpasque
Copy link
Contributor

dpasque commented Aug 24, 2023

After some more designing today, I had the idea to split up up the block smoke testing for forms and the full flow.

This means, two specs:

  • blocks__jetpack-forms, which will itself include three flows...
    • One where you add a pre-canned Contact Form
    • One where you add all the possible fields
    • One where you transform a Form block using the custom pattern options.
  • jetpack__full-form-flow, which will use a very basic form (like RSVP) and go through submission and validation.

@worldomonation
Copy link
Contributor Author

⬆️ Sounds good to me.

One nitpick suggestion: what if the full spec is named like jetpack__rsvp-flow?

@dpasque
Copy link
Contributor

dpasque commented Aug 25, 2023

One nitpick suggestion: what if the full spec is named like jetpack__rsvp-flow?

Oh that's fine too! Although, I'm not sure I want to necessarily couple it tightly to a specific type of form, because we might change that based on whatever is easiest --- the focus isn't the form content, but that you can submit forms on webpages and see the responses in Admin!

@dpasque
Copy link
Contributor

dpasque commented Sep 6, 2023

Adding some test plan mapping notes / ideas:

Jetpack Social - Social preview

This test actually shouldn't be that hard, and would be a good test! We could just...

  1. Make a new post
  2. Open the Jetpack Sidebar
  3. Add an "SEO Title"
  4. Launch the preview and validate one or two social media previews.

Jetpack Newsletter - editor sidebar access settings

I added this because I think this is a big money maker for us, and I think any coverage here could be good.
We could set up a paid newsletter plan on these accounts, but we don't necessarily need paid subscribers. Even a test that sets it to paid subscribers and makes sure that any ol' person on the internet can't view the post. We can maybe also have a dedicated user that has a free subscription on all of these sites.

Jetpack Social - Auto-share to social on publish

It looks like the simple sites may have a tumblr connection already set up, so we might be able to use that to test a very simple/basic version of this case!

@worldomonation
Copy link
Contributor Author

Can we check for the Stats pixel.wp.com request on the front-end of WPCOM sites somehow?

It looks like we have a tracking pixel and its details are here: p7pQDF-5HJ-p2.

Basically, we want to see if the request for a tracking pixel (at pixel.wp.com) succeeded, and that should be enough to verify that at least the frontend loaded the tracking pixel. From our last Jetpack <> KitKat meeting, I'm pretty sure it's going to be difficult to then query whether the tracked stat made its way back to the database.

@jeherve does the above sound okay?

@jeherve
Copy link
Member

jeherve commented Sep 14, 2023

Yes, I think checking for the https://pixel.wp.com/g.gif should be enough. You would want to check for specific parameters with that request, since other a8c tracking solutions such as Tracks can also use g.gif but with different parameters.

Checking for the blog and post parameters should be good to ensure this is a Stats tracking pixel.

@worldomonation
Copy link
Contributor Author

worldomonation commented Oct 12, 2023

Yes, I think checking for the https://pixel.wp.com/g.gif should be enough. You would want to check for specific parameters with that request, since other a8c tracking solutions such as Tracks can also use g.gif but with different parameters.

Checking for the blog and post parameters should be good to ensure this is a Stats tracking pixel.

Edit: I figured it out for AT sites - the tracking pixels don't load if viewing the post as the publishing user, unlike on Simple where it does. Solution is to view the post as a logged out user.

Oddly, it seems on the AT blogs the tracking pixel isn't being loaded. These are the only requests I see:

@jeherve

@jeherve
Copy link
Member

jeherve commented Oct 12, 2023

it seems on the AT blogs the tracking pixel isn't being loaded.

Is the Stats module enabled on those sites?

Solution is to view the post as a logged out user.

Another option could be to change the Stats options to allow tracking logged in users as well, but that may be more steps.

@worldomonation
Copy link
Contributor Author

it seems on the AT blogs the tracking pixel isn't being loaded.

Is the Stats module enabled on those sites?

Yes, it is enabled. The issue as I found out is a behavior difference between AT and Simple sites.

  • Simple: loads tracking pixels even if viewing as the publishing user.
  • AT: does not load tracking pixel if viewing as publishing user.

Solution is to view the post as a logged out user.

Another option could be to change the Stats options to allow tracking logged in users as well, but that may be more steps.

To clarify, the tracking pixel is being loaded as logged out user on AT and Simple. The only time the tracking pixel isn't loading on AT is when viewing the published post as the publishing user.

In any case, we want to view the post not as the publishing user.

@dpasque
Copy link
Contributor

dpasque commented Oct 13, 2023

Going to go ahead and close this now, as we are at the end of our window for implementing these test. We've gotten the vast vast vast majority of the items here, and increased the coverage a lot!

@dpasque dpasque closed this as completed Oct 13, 2023
@github-project-automation github-project-automation bot moved this from In Progress to Done🎊 in KitKat Project Board Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

3 participants