Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Have a changeable default contribution amount for new installs (until user locks value) #12573

Closed
bsclifton opened this issue Jan 9, 2018 · 4 comments

Comments

@bsclifton
Copy link
Member

bsclifton commented Jan 9, 2018

Test plan

Should be ran via npm run watch / npm start since editing code is involved

Test Case 1

Make sure default is change-able

  1. Fresh install of Brave / profile
  2. Preferences > Payments, enable payments
  3. Default contribution amount should be lowest amount available (currently 5.0 BAT)
  4. Close Brave and open js/constants/appConfig.js
  5. Change payments.defaultContributionAmount to 10
  6. Re-launch Brave and see default amount updated to 10

Test Case 2

Make sure value doesn't change once it's set

  1. Fresh install of Brave / profile
  2. Preferences > Payments, enable payments
  3. Default contribution amount should be lowest amount available (currently 5.0 BAT)
  4. Change the monthly budget to another value (example: 17.5 BAT)
  5. Close Brave and open js/constants/appConfig.js
  6. Change payments.defaultContributionAmount to 10
  7. Re-launch Brave and see contribution amount remain 17.5

Test Case 3

Make sure value doesn't change once funds are added

  1. Fresh install of Brave / profile
  2. Launch using LEDGER_ENVIRONMENT=staging (see here for more info on flags)
  3. Preferences > Payments, enable payments
  4. Default contribution amount should be lowest amount available (currently 5.0 BAT)
  5. Use the Uphold Sandbox account and transfer BAT to the address shown in Brave
  6. Once the funds show in Brave, exit the browser
  7. Open js/constants/appConfig.js and change payments.defaultContributionAmount to 10
  8. Re-launch Brave and see contribution amount remain 5.0

Description

For completely new installs, the default amount should be easily changeable. The value it has should come from a config and would be considered "floating" until the user takes an action to "lock it in"

  • Manually choosing a value
  • Funding wallet
  • Accepting a grant (via user growth pool)

In those cases, the value that is set gets "locked in" and can only be changed by the user.

Existing installs are not affected by this change. They already have their values locked in.

@bsclifton bsclifton added this to the 0.19.x Hotfix 12 milestone Jan 9, 2018
@bsclifton bsclifton self-assigned this Jan 9, 2018
@mrose17
Copy link
Member

mrose17 commented Jan 9, 2018

@bsclifton - i suggest that the default contribution be the smallest amount available, not hardwired to "5BAT"...

@bsclifton bsclifton changed the title Update default contribution for new installs to 5 BAT Update default contribution for new installs to smallest amount available Jan 9, 2018
@bsclifton
Copy link
Member Author

@mrose17 title updated

@bsclifton bsclifton changed the title Update default contribution for new installs to smallest amount available Have a changeable default contribution amount for new installs (until user locks value) Jan 10, 2018
@srirambv
Copy link
Collaborator

All 3 test cases worked on Windows

@kjozwiak
Copy link
Member

@LaurenWags and myself ran through these cases once again with 0.19.134 which included the following change:

  • changing default from 5.0 BAT to 7.5 BAT

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.