brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.
https://brave.com
Mozilla Public License 2.0
17.85k stars 2.33k forks source link

[Desktop] Update BAP UI #13701

Closed zenparsing closed 3 years ago

zenparsing commented 3 years ago

See https://github.com/brave/internal/issues/747.

GeetaSarvadnya commented 3 years ago

Verification passed on


Brave | 1.20.104 Chromium: 88.0.4324.152 (Official Build) (64-bit)
-- | --
Revision | 6579930fc53b4dc589c042bec9d0a3778326974d-refs/branch-heads/4324@{#2106}
OS | Windows 10 OS Version 2004 (Build 19041.804)

Scenario 1: Non-JP Regions

(Additional testing will be covered in https://github.com/brave/brave-browser/issues/14207) Scenario 2: JP Regions

Scenario 3: JP Regions (Promotions)

Verified FIXED using

Brave 1.20.104 Chromium: 88.0.4324.152 (Official Build) (x86_64)
Revision 6579930fc53b4dc589c042bec9d0a3778326974d-refs/branch-heads/4324@{#2106}
OS macOS Version 11.2.1 (Build 20D74)

Scenario 1: Non-JP Regions

Open the browser in rewards staging environment. Open the rewards panel and claim the promotion. Wait for the promotion value to appear in the wallet balance on the panel. Close the rewards panel and open a new tab. Verify that the BAP popup does not appear on the new tab page. Close the new tab page. Advance the system time to 2021-03-06. Open a new tab page.

Verify that the BAP alert does not appear on the new tab page.

screenshot Screen Shot 2021-03-06 at 2 06 22 PM
Close the new tab page. Advance the system time to 2021-03-13. Open a new tab page and open the rewards panel.

Verify that the wallet balance is not zero.

screenshot Screen Shot 2021-03-13 at 2 02 58 PM

Scenario 2: JP Regions

Set the system region to JP. Open the browser in rewards staging environment. Open the new tab page.

Verify that the BAP popup does not appear (because the user's balance is zero).

screenshot スクリーンショット 2021-02-17 13 37 35
Close the new tab page. Open the rewards panel and claim the promotion. Wait for the promotion value to appear in the wallet balance on the panel.

Close the rewards panel and open a new tab. Verify that the BAP popup appears.

screenshot スクリーンショット 2021-02-17 13 39 17

Click the "Learn more" button on the popup. Verify that the BAP alert appears in the new tab page.

screenshot スクリーンショット 2021-02-17 13 40 26
Close the BAP alert and the new tab page. Open a new tab. Verify that the BAP popup does not appear. Close the new tab page.

Advance the system time to 2021-02-20 Open a new tab page. Verify that the BAP popup is displayed.

screenshot スクリーンショット 2021-02-20 13 42 04

Close the new tab page. Advance the system time to 2021-03-06. Open the new tab page. Verify that the BAP alert is displayed.

screenshot スクリーンショット 2021-03-06 13 43 57
Dismiss the BAP alert by clicking the "X" button and close the new tab page. Open a tab. Verify that the BAP alert is not displayed. Close the tab.

Advance the system time by 3 days, to 2021-03-09 Open a tab. Verify that the BAP alert is displayed.

screenshot スクリーンショット 2021-03-09 13 46 36
Click the "OK" button on the BAP alert. Close the tab. Open a tab. Verify that the BAP alert is not displayed. Close the tab.

Advance the system time to 2021-03-13. Open a new tab. Verify that the BAP popup and the BAP alert are not displayed.

screenshot スクリーンショット 2021-03-13 13 48 13

Open the rewards panel. Verify that zero is shown for the user's balance.

screenshot スクリーンショット 2021-03-13 13 20 43

Scenario 3: JP Regions (Promotions)

Set the system region to JP. Advance the system time to 2021-03-13. Open the browser in rewards staging environment. Open the rewards panel. Verify that no grant promotions are displayed to the user.

screenshot スクリーンショット 2021-03-13 13 21 22

Verification passed on

Brave 1.20.104 Chromium: 88.0.4324.152 (Official Build) (64-bit)
Revision 6579930fc53b4dc589c042bec9d0a3778326974d-refs/branch-heads/4324@{#2106}
OS Ubuntu 18.04 LTS

Scenario 1: Non-JP Regions

Scenario 2: JP Regions

Scenario 3: JP Regions (Promotions)

kjozwiak commented 3 years ago

Moving this into 1.22.x as the BAP work is being reverted via https://github.com/brave/brave-core/pull/8088. Once we have more information next week, we'll re-revert https://github.com/brave/brave-core/pull/8088 and move everything back into 1.21.x and release 1.21.x - Release #2.

GeetaSarvadnya commented 3 years ago

Verification passed on


Brave | 1.21.76 Chromium: 89.0.4389.86 (Official Build) (64-bit)
-- | --
Revision | 0c2dac31bc21e806a791641316e99920f84ea52c-refs/branch-heads/4389@{#1472}
OS | Windows 10 OS Version 2004 (Build 19041.804)
Brave | 1.21.76 Chromium: 89.0.4389.86 (Official Build) (64 ビット)
-- | --
変更履歴 | 0c2dac31bc21e806a791641316e99920f84ea52c-refs/branch-heads/4389@{#1472}
OS | Windows 8.1 (Build 9600.19817)

Verified the test plan from https://github.com/brave/brave-core/pull/7698

Scenario 1: Non-JP Regions - Ensured that users can claim the UGP grants - Ensured that promotion value is displayed in the wallet balance - Ensured there is no BAP popup display in the NTP - Ensured that user can send one-time tip/recurring tip to regular pubs - Ensured that user can send one-time tip/recurring tip to media pubs - Ensured one-time tips displayed under the Tips panel - Ensured recurring tips displayed under the Monthly Contributions - Verified that pubs can be added to the AC table - Ensured that tips sent to nonverified pubs are stored in the pending contribution table Verified no BAP alert displayed for non-Japan region (used US) under https://github.com/brave/brave-browser/issues/14315#issuecomment-796560447 (Test case 12) Verified the following: - Confirmed able to claim promotion - Confirmed BAP alert does not appear on NTP - Confirmed wallet balance is not zero when system date is set to 2021-03-13
Scenario 2: JP Regions Ensured BAP popup does not appear in new tab page as wallet balance is zero ![image](https://user-images.githubusercontent.com/38657976/110783043-e477fb00-828d-11eb-80ea-76e6f7478a56.png) Ensured able to claim grants from BR panel and promotion value appeared in the wallet balance ![image](https://user-images.githubusercontent.com/38657976/110783206-243ee280-828e-11eb-8d84-f011e58f28a0.png) ![image](https://user-images.githubusercontent.com/38657976/110783245-2f920e00-828e-11eb-96af-bdc4d250dd34.png) ![image](https://user-images.githubusercontent.com/38657976/110783287-3d479380-828e-11eb-945f-09a0e1dfe3c2.png) Note - BAP popup/tool tip is no longer valid as it only showed prior to March 6. Verified the following per the above listed issue(s): - Confirmed with zero BAP balance there is no BAP alert - Confirmed able to claim UGP grant prior to March 13 - Confirmed BAP alert displays when there is a non-zero BAP balance - Confirmed able to close the BAP alert via "OK" - Confirmed able to close the BAP alert via "x" - Confirmed opening a NTP did show the BAP alert again when it had not been dismissed - Confirmed opening a NTP did not show the BAP alert again when it had been dismissed - Confirmed BAP alert displayed daily until March 13 - Confirmed when computer date is 2021-03-13 and first NTP is opened, the BAP alert is not displayed - Confirmed that the BAP balance is now zero on the panel and brave://rewards
Scenario 3: JP Region (Promotions) Checked with Japan/Japanese. Using a clean profile, confirmed when date = 2021-03-13, no promotions are fetched. Example | Example ----- | ----- ![image](https://user-images.githubusercontent.com/38657976/110838324-579e6300-82c8-11eb-811e-6acae8284008.png) | ![image](https://user-images.githubusercontent.com/38657976/110838431-73a20480-82c8-11eb-9a0d-8211c0e74968.png) Saw the below item in my logs: ``` [9480:9576:0313/100438.766:VERBOSE1:promotion.cc(116)] Fetch promotions disabled for BAP migration ``` Checked with US/English. Using a clean profile, confirmed when date = 2021-03-13, promotions are fetched. ![image](https://user-images.githubusercontent.com/38657976/110838906-0347b300-82c9-11eb-9ac1-21543a444941.png) | ``` [ REQUEST ] > URL: https://grant.rewards.bravesoftware.com/v1/promotions?migrate=true&platform=windows > Method: UrlMethod::GET [27376:5404:0313/234053.495:VERBOSE1:publisher_prefix_list_updater.cc(102)] Resetting publisher prefix list table [27376:5404:0313/234053.497:VERBOSE1:database_publisher_prefix_list.cc(123)] Clearing publisher prefixes table [27376:5404:0313/234053.597:VERBOSE1:database_publisher_prefix_list.cc(133)] Inserting 100000 records into publisher prefix table [27376:5404:0313/234054.142:VERBOSE1:database_publisher_prefix_list.cc(133)] Inserting 100000 records into publisher prefix table [27376:5404:0313/234054.292:VERBOSE6:logging_util.cc(136)] [ RESPONSE - OnRequest ] > Url: https://grant.rewards.bravesoftware.com/v1/promotions?migrate=true&platform=windows > Result: Success > HTTP Code: 200 > Body: {"promotions":[{"id":"f05568e6-f4a1-4438-8e81-cc0490fd14f7","createdAt":"2021-03-10T14:42:34.631225Z","expiresAt":"2021-07-10T14:42:34.631225Z","version":5,"suggestionsPerGrant":120,"approximateValue":"3 ```

Verified passed with

Brave   1.21.76 Chromium: 89.0.4389.86 (Official Build) (x86_64)
Revision    0c2dac31bc21e806a791641316e99920f84ea52c-refs/branch-heads/4389@{#1472}
OS  macOS Version 10.15.7 (Build 19H524)
Scenario 1: Non-JP Regions Verified no BAP alert displayed for non-Japan region (used US) under https://github.com/brave/brave-browser/issues/14570#issuecomment-796466032. Verified the following: - Confirmed able to claim promotion - Confirmed BAP alert does not appear on NTP - Confirmed wallet balance is not zero when system date is set to 2021-03-13
Scenario 2: JP Region Verified BAP alert frequency with https://github.com/brave/brave-browser/issues/14570#issuecomment-796466032 Note - BAP popup/tool tip is no longer valid as it only showed prior to March 6. Verified the following per the above listed issue(s): - Confirmed with zero BAP balance there is no BAP alert - Confirmed able to claim UGP grant prior to March 13 - Confirmed BAP alert displays when there is a non-zero BAP balance - Confirmed able to close the BAP alert via "OK" - Confirmed able to close the BAP alert via "x" - Confirmed opening a NTP did show the BAP alert again when it had not been dismissed - Confirmed opening a NTP did not show the BAP alert again when it had been dismissed - Confirmed BAP alert displayed daily until March 13 - Confirmed when computer date is 2021-03-13 and first NTP is opened, the BAP alert is not displayed - Confirmed that the BAP balance is now zero on the panel and brave://rewards
Scenario 3: JP Region (Promotions) Checked with Japan/Japanese. Using a clean profile, confirmed when date = 2021-03-13, no promotions are fetched. Example | Example ----- | ----- Mar13-1-Japan | Mar-13-2-Japan Saw the below item in my logs: ``` [14787:775:0313/100536.798510:VERBOSE1:promotion.cc(116)] Fetch promotions disabled for BAP migration ``` Checked with US/English. Using a clean profile, confirmed when date = 2021-03-13, promotions are fetched. Example | Example ----- | ----- Mar13-1-US | Mar13-2-US Saw the below in my logs: ``` [ REQUEST ] > URL: https://grant.rewards.bravesoftware.com/v1/promotions?migrate=true&platform=osx > Method: UrlMethod::GET [14913:775:0313/100753.645109:VERBOSE6:logging_util.cc(136)] [ RESPONSE - OnRequest ] > Url: https://grant.rewards.bravesoftware.com/v1/promotions?migrate=true&platform=osx > Result: Success > HTTP Code: 200 > Body: {"promotions":[{"id":"f05568e6-f4a1-4438-8e81-cc0490fd14f7","createdAt":"2021-03-10T14:42:34.631225Z","expiresAt":"2021-07-10T14:42:34.631225Z","version":5,"suggestionsPerGrant":120,"approximateValue":"30","type":"ugp","available":true,"platform":"desktop","publicKeys":["6AphTvx13IgxVRG1nljV2ql1Y7yGUol6yrVMhEP85wI="],"legacyClaimed":false}]} ```

Verification passed on

Brave 1.21.76 Chromium: 89.0.4389.86 (Official Build) (64-bit)
Revision 0c2dac31bc21e806a791641316e99920f84ea52c-refs/branch-heads/4389@{#1472}
OS Ubuntu 18.04 LTS
Scenario 1: Non-JP Regions Verified no BAP alert displayed for non-Japan region (used US) under https://github.com/brave/brave-browser/issues/14570#issuecomment-796466032. Verified the following: - Confirmed able to claim promotion - Confirmed BAP alert does not appear on NTP - Confirmed wallet balance is not zero when system date is set to 2021-03-13
Scenario 2: JP Region Verified BAP alert frequency with https://github.com/brave/brave-browser/issues/14570#issuecomment-796466032 Note - BAP popup/tool tip is no longer valid as it only showed prior to March 6. Verified the following per the above listed issue(s): - Confirmed with zero BAP balance there is no BAP alert - Confirmed able to claim UGP grant prior to March 13 - Confirmed BAP alert displays when there is a non-zero BAP balance - Confirmed able to close the BAP alert via "OK" - Confirmed able to close the BAP alert via "x" - Confirmed opening a NTP did show the BAP alert again when it had not been dismissed - Confirmed opening a NTP did not show the BAP alert again when it had been dismissed - Confirmed BAP alert displayed daily until March 13 - Confirmed when computer date is 2021-03-13 and first NTP is opened, the BAP alert is not displayed - Confirmed that the BAP balance is now zero on the panel and brave://rewards
Scenario 3: JP Region (Promotions) Checked with Japan/Japanese. Using a clean profile, confirmed when date = 2021-03-14, no promotions are fetched. Example | Example ----- | ----- ![image](https://user-images.githubusercontent.com/34715963/110822739-a7ae0300-8291-11eb-859c-950f6be4cf0f.png)|![image](https://user-images.githubusercontent.com/34715963/110822771-b2689800-8291-11eb-8c77-7a5826b45efd.png) Saw the below item in my logs: ``` [28911:28911:0314/174403.128344:VERBOSE1:wallet_balance.cc(34)] Fetch balance disabled for BAP migration ``` Checked with PL/Polish. Using a clean profile, confirmed when date = 2021-03-14, promotions are fetched. Example | Example | Example | Example ----- | ----- | ----- | ----- ![image](https://user-images.githubusercontent.com/34715963/110823033-fbb8e780-8291-11eb-90da-9cb7fa3599e2.png) ![image](https://user-images.githubusercontent.com/34715963/110823073-04a9b900-8292-11eb-88b8-0e853c7e19b4.png) ![image](https://user-images.githubusercontent.com/34715963/110823104-0ffce480-8292-11eb-937e-cde4bf7dfc6c.png) ![image](https://user-images.githubusercontent.com/34715963/110823136-155a2f00-8292-11eb-95eb-ef524c3268db.png) Saw the below in my logs: ``` [ RESPONSE - OnRequest ] > Url: https://grant.rewards.bravesoftware.com/v1/promotions?migrate=true&platform=linux > Result: Success > HTTP Code: 200 > Body: {"promotions":[{"id":"f05568e6-f4a1-4438-8e81-cc0490fd14f7","createdAt":"2021-03-10T14:42:34.631225Z","expiresAt":"2021-07-10T14:42:34.631225Z","version":5,"suggestionsPerGrant":120,"approximateValue":"30","type":"ugp","available":true,"platform":"desktop","publicKeys":["6AphTvx13IgxVRG1nljV2ql1Y7yGUol6yrVMhEP85wI="],"legacyClaimed":false}]} ```