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

[DDW-824] Fix app update on specific platform #2759

Merged
merged 7 commits into from Dec 3, 2021

Conversation

tomislavhoracek
Copy link
Contributor

@tomislavhoracek tomislavhoracek commented Nov 26, 2021

This PR introduces a fix for app update on specific platform.

Todos

  • Remove new app version declaration (4.5.2) or merge develop with version update
  • Revert isDev flag to FAKED new loader once QA is done

Screenshots

- No screenshots


Testing Checklist

NOTES:

  • We need to manually load news so we can fake automatic update news
  • Since we can't update Daedalus to some upcoming release (those faked releases even doesn't exist) we will fake Daedalus version and pretend that updated was sucessfull

What we want to simulate:

  • We have 2 updates. First update to version 5.1.0 is for all platforms and the second one is special Windows ONLY update. We want to ensure that first update is visible for all platforms as well as release notes after the update and to ensure that second update is only visible on Windows after the first update.

Faked News:
https://github.com/input-output-hk/daedalus/blob/f5c2b5470dbc45c2b0d0e800f3f35dab44786709/source/renderer/app/config/newsfeed-files/news-automatic-update.dummy.json

Testing:

1. Windows

  • Load News with current (not faked) Daedalus app version
    daedalus.stores.newsFeed.setFakedNewsfeed({ isAutomaticUpdateTest: true })

  • Now you should see available update to version 5.1.0

  • Refresh Daedalus

  • Now we will fake Daedalus version 5.1.0 to simulate app update (finished)
    daedalus.stores.newsFeed.setFakedNewsfeed({ isAutomaticUpdateTest: true, appVersion: "5.1.0" })

  • You should see available update to 5.1.1 and release notes for 5.1.0

  • Refresh Daedalus

  • Now we will fake Daedalus version 5.1.1 to simulate app update (finished)
    daedalus.stores.newsFeed.setFakedNewsfeed({ isAutomaticUpdateTest: true, appVersion: "5.1.1" })

  • You should not see available updates but you should see 5.1.1 release notes

2. Mac / Linux

  • Load News with current (not faked) Daedalus app version
    daedalus.stores.newsFeed.setFakedNewsfeed({ isAutomaticUpdateTest: true })

  • Now you should see available update to version 5.1.0

  • Refresh Daedalus

  • Now we will fake Daedalus version 5.1.0 to simulate app update (finished)
    daedalus.stores.newsFeed.setFakedNewsfeed({ isAutomaticUpdateTest: true, appVersion: "5.1.0" })

  • You should see release notes for 5.1.0. You should not see available update to version 5.1.1 because that update is declared as Windows ONLY


Review Checklist

Basics

  • PR has been assigned and has appropriate labels (feature/bug/chore, release-x.x.x)
  • PR is updated to the most recent version of the target branch (and there are no conflicts)
  • PR has a good description that summarizes all changes
  • PR has default-sized Daedalus window screenshots or animated GIFs of important UI changes:
    • In English
    • In Japanese
  • CHANGELOG entry has been added to the top of the appropriate section (Features, Fixes, Chores) and is linked to the correct PR on GitHub
  • Automated tests: All acceptance and unit tests are passing (yarn test)
  • Manual tests (minimum tests should cover newly added feature/fix): App works correctly in development build (yarn dev)
  • Manual tests (minimum tests should cover newly added feature/fix): App works correctly in production build (yarn package / CI builds)
  • There are no flow errors or warnings (yarn flow:test)
  • There are no lint errors or warnings (yarn lint)
  • There are no prettier errors or warnings (yarn prettier:check)
  • There are no missing translations (running yarn manage:translations produces no changes)
  • Text changes are proofread and approved (Jane Wild / Amy Reeve)
  • Japanese text changes are proofread and approved (Junko Oda)
  • UI changes look good in all themes (Alexander Rukin)
  • Storybook works and no stories are broken (yarn storybook)
  • In case of dependency changes yarn.lock file is updated

Code Quality

  • Important parts of the code are properly commented and documented
  • Code is properly typed with flow
  • React components are split-up enough to avoid unnecessary re-renderings
  • Any code that only works in main process is neatly separated from components

Testing

  • New feature/change is covered by acceptance tests
  • New feature/change is manually tested and approved by QA team
  • All existing acceptance tests are still up-to-date
  • New feature/change is covered by Daedalus Testing scenario
  • All existing Daedalus Testing scenarios are still up-to-date

After Review

  • Merge the PR
  • Delete the source branch
  • Move the ticket to done column on the YouTrack board
  • Update Slack QA thread by marking it with a green checkmark

Copy link

@miorsufianiohk miorsufianiohk left a comment

Choose a reason for hiding this comment

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

LGTM. Great work @tomislavhoracek . Tested on build 19848 Mainnet/Flight/Testnet for all 3 platforms Win/Lin/Mac 👍

@ManusMcCole ManusMcCole self-requested a review December 2, 2021 10:06
Copy link

@ManusMcCole ManusMcCole left a comment

Choose a reason for hiding this comment

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

Looks good @tomislavhoracek 🚀

@tomislavhoracek tomislavhoracek requested review from danielmain and a team December 2, 2021 10:40
Copy link
Contributor

@danielmain danielmain left a comment

Choose a reason for hiding this comment

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

Thank you @tomislavhoracek this is a huge help for testing the automatic update!

@danielmain danielmain merged commit 87feb8e into develop Dec 3, 2021
@iohk-bors iohk-bors bot deleted the fix/ddw-824-fix-app-update-on-specific-platform branch December 3, 2021 09:11
@danielmain danielmain added release-4.6.0 Daedalus Mainnet and removed ⏳release-vNext labels Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug release-4.6.0 Daedalus Mainnet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants