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 #1562: Bug fix promoted story list #1564

Merged
merged 2 commits into from
Aug 6, 2020
Merged

Conversation

rt4914
Copy link
Contributor

@rt4914 rt4914 commented Aug 6, 2020

Explanation

Fixes #1562

In #1554 we noticed one issue, if user have progress in old stories but not in recent stories, the home screen promoted stories looks empty but the RecentlyPlayedActivity looks correct. So to fix this I have optimised the logic a bit.

  1. If there are recent stories, only recent stories will be show in HomeActivity and not the old-stories.
  2. If there are no recent stories, then old stories will be show in HomeActivity as recent stories, because that's the most recent stories from user perspective.

This will further be improvised once we have Recommended Stories in place as part of #936

How to test

Using StoryProgressTestHelper make partial progress but as old story using following code.

   storyProgressTestHelper.markPartialStoryProgressForFractions(profileId, true)
   storyProgressTestHelper.markTwoPartialStoryProgressForRatios(profileId, true)

Screenshot

Screenshot_1596712534
Screenshot_1596712540

Checklist

  • The PR title starts with "Fix #bugnum: ", followed by a short, clear summary of the changes. (If this PR fixes part of an issue, prefix the title with "Fix part of #bugnum: ...".)
  • The PR explanation includes the words "Fixes #bugnum: ..." (or "Fixes part of #bugnum" if the PR only partially fixes an issue).
  • The PR follows the style guide.
  • The PR does not contain any unnecessary auto-generated code from Android Studio.
  • The PR is made from a branch that's not called "develop".
  • The PR is made from a branch that is up-to-date with "develop".
  • The PR's branch is based on "develop" and not on any other branch.
  • The PR is assigned to an appropriate reviewer in both the Assignees and the Reviewers sections.

Copy link
Contributor

@anandwana001 anandwana001 left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks

@anandwana001 anandwana001 assigned rt4914 and unassigned anandwana001 Aug 6, 2020
@rt4914 rt4914 merged commit 46aa6e5 into develop Aug 6, 2020
@rt4914 rt4914 deleted the bug-fix-promoted-story-list branch August 6, 2020 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Show correct PromotedStories if progress is available but not for last week.
2 participants