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

Fix conditions for showing the publication approved overlay notification #9089

Closed
1 task
techanvil opened this issue Jul 29, 2024 · 5 comments
Closed
1 task
Labels
Module: RRM Reader Revenue Manager module related issues P0 High priority Team M Issues for Squad 2 Type: Enhancement Improvement of an existing feature

Comments

@techanvil
Copy link
Collaborator

techanvil commented Jul 29, 2024

Feature Description

When the onboarding state for the current publication is synced, the publication approved overlay notification should appear, but only when the onboarding state has changed from another non-empty state.

At present the notification will appear even if the publication was already in the onboarding state prior to the sync. See https://github.com/google/site-kit-wp/pull/9017/files#r1693880442.


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • While viewing the dashboard, when the onboarding state for the current publication is synced, the publication approved overlay notification should appear, but only when the onboarding state has changed from another non-empty state.

Implementation Brief

  • In assets/js/modules/reader-revenue-manager/datastore/publications.js, update following condition

if (
onboardingState ===
PUBLICATION_ONBOARDING_STATES.ONBOARDING_COMPLETE
) {

add following check along with existing one

onboardingState !== currentOnboardingState

Test coverage

  • Add the test coverage for status transition change.

QA Brief

  • Set up Site Kit with a Google account that has one or more publications in the publisher center.
  • Using the tester plugin, enable the rrmModule feature flag, and change the "_
    Force Reader Revenue Manager publication onboarding state_" setting to something other than ONBOARDING_COMPLETE.
  • Set up the RRM module.
  • Go to the Site Kit dashboard and verify that the publication approved overlay notification is not shown.
  • Go to the tester plugin and change the RRM setting to ONBOARDING_COMPLETE.
  • Go back to the dashboard and in the browser console, run the following script:
googlesitekit.data.dispatch( 'modules/reader-revenue-manager' ).syncPublicationOnboardingState()

Changelog entry

  • N/A
@techanvil techanvil added P0 High priority Type: Enhancement Improvement of an existing feature labels Jul 29, 2024
@nfmohit
Copy link
Collaborator

nfmohit commented Jul 30, 2024

AC ✅

Thank you @techanvil !

@nfmohit nfmohit added Team M Issues for Squad 2 Module: RRM Reader Revenue Manager module related issues labels Jul 30, 2024
@nfmohit nfmohit removed their assignment Jul 30, 2024
@ankitrox ankitrox assigned ankitrox and unassigned ankitrox Jul 31, 2024
@nfmohit nfmohit self-assigned this Jul 31, 2024
@nfmohit
Copy link
Collaborator

nfmohit commented Aug 6, 2024

The IB looks good to me, @ankitrox. Would you agree that it would be wise to increase the estimate to a 7 at least, considering there's test coverage involved? If so, could you please update the estimate? Thank you!

@nfmohit nfmohit assigned ankitrox and unassigned nfmohit Aug 6, 2024
@ankitrox
Copy link
Collaborator

ankitrox commented Aug 6, 2024

Hi @nfmohit

Thanks for flagging this. I had been conservative, but this exceeds the estimated time considering the fact that we may have to adjust test cases and may encounter some unforeseen scenarios.

I have updated estimate to 7 as it sounds correct.

Thanks again.

@nfmohit
Copy link
Collaborator

nfmohit commented Aug 6, 2024

Thank you @ankitrox !

IB ✅

@wpdarren
Copy link
Collaborator

wpdarren commented Aug 8, 2024

QA Update: ✅

Verified:

Onboarding state setting to something other than ONBOARDING_COMPLETE.

Onboarding state setting to ONBOARDING_COMPLETE.

  • After a few seconds, the publication approved overlay notification is displayed.

Refreshing the page and running the above script again.

  • The overlay notification is no longer displayed.

Besides the above, I also performed a smoke test using the QAB for #8796 and #8797. I will be creating a more thorough smoke test of the entire RRM functionality as approaching the completion of the bug bash instructions.

image

@wpdarren wpdarren removed their assignment Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Module: RRM Reader Revenue Manager module related issues P0 High priority Team M Issues for Squad 2 Type: Enhancement Improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

6 participants