wordpress-mobile / WordPress-Android

WordPress for Android
http://android.wordpress.org
GNU General Public License v2.0
2.92k stars 1.3k forks source link

Add new Subscribers tab #20685

Closed aditi-bhatia closed 3 weeks ago

aditi-bhatia commented 3 weeks ago

Fixes https://github.com/wordpress-mobile/WordPress-Android/issues/20680

This PR adds in some basic groundwork for the new Subscribers tab, which is feature flagged behind stats_traffic_subscribers_tab. It is currently using mapInsights from UiModelMapper.kt as a placeholder for now, which is why you will see the screen below:

Screenshot 2024-04-22 at 4 43 22 PM

I've left the uses cases empty for now as that work can be done in a separate PR.


To Test:

  1. With the stats_traffic_subscribers_tab feature flag on, ensure you see the Subscribers tab as it appears in the screenshot above.
  2. Accessing the Subscribers tab should fire the stats_subscribers_accessed tracked event.
  3. With the stats_traffic_subscribers_tab feature flag off, ensure you don't see the Subscribers tab and the weeks/days/months tabs appear as expected.

Regression Notes

  1. Potential unintended areas of impact

    • States related to the stats_traffic_subscribers_tab feature flag
  2. What I did to test those areas of impact (or what existing automated tests I relied on)

    • Manual testing
  3. What automated tests I added (or what prevented me from doing so)

    • Tests will be updated in future PRs as development continues

PR Submission Checklist:


Testing Checklist (strike-out the not-applying and unnecessary ones):

dangermattic commented 3 weeks ago
2 Warnings
:warning: strings.xml files should only be updated on release branches, when the translations are downloaded by our automation.
:warning: PR is not assigned to a milestone.

Generated by :no_entry_sign: Danger

wpmobilebot commented 3 weeks ago
WordPress📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
App NameWordPress WordPress
FlavorJalapeno
Build TypeDebug
Versionpr20685-2112f8f
Commit2112f8f75c13f9de90e4b54dfed22f7ffc92aec2
Direct Downloadwordpress-prototype-build-pr20685-2112f8f.apk
Note: Google Login is not supported on these builds.
wpmobilebot commented 3 weeks ago
Jetpack📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
App NameJetpack Jetpack
FlavorJalapeno
Build TypeDebug
Versionpr20685-2112f8f
Commit2112f8f75c13f9de90e4b54dfed22f7ffc92aec2
Direct Downloadjetpack-prototype-build-pr20685-2112f8f.apk
Note: Google Login is not supported on these builds.
codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 10.52632% with 17 lines in your changes are missing coverage. Please review.

Project coverage is 40.62%. Comparing base (ed25d7d) to head (2112f8f).

Files Patch % Lines
...droid/ui/stats/refresh/lists/StatsListViewModel.kt 6.66% 14 Missing :warning:
...rdpress/android/ui/stats/refresh/StatsViewModel.kt 0.00% 2 Missing :warning:
.../wordpress/android/ui/stats/refresh/StatsModule.kt 0.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## trunk #20685 +/- ## ========================================== - Coverage 40.63% 40.62% -0.01% ========================================== Files 1485 1485 Lines 68288 68307 +19 Branches 11296 11296 ========================================== + Hits 27746 27748 +2 - Misses 38029 38046 +17 Partials 2513 2513 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

sonarcloud[bot] commented 3 weeks ago

Quality Gate Passed Quality Gate passed

Issues
1 New issue
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

irfano commented 3 weeks ago

I'm merging but I want to remind you that you can complete the "Regression Notes", "PR Submission Checklist" and "Testing Checklist" sections after the merge, @aditi-bhatia.

aditi-bhatia commented 3 weeks ago

Thank you for the reminder! I've gone ahead and updated those sections.