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

Calculate account statement from locally persisted state #16028

Closed
tmancey opened this issue May 21, 2021 · 9 comments · Fixed by brave/brave-core#10956
Closed

Calculate account statement from locally persisted state #16028

tmancey opened this issue May 21, 2021 · 9 comments · Fixed by brave/brave-core#10956
Assignees
Labels
1_point For Agile sizing enhancement feature/ads OS/Android Fixes related to Android browser functionality OS/Desktop OS/iOS Fixes related to iOS browser functionality priority/P3 The next thing for us to work on. It'll ride the trains. QA Pass - Android ARM QA Pass - Android Tab QA Pass-Win64 QA/Yes release-notes/exclude
Projects

Comments

@tmancey
Copy link
Collaborator

tmancey commented May 21, 2021

No description provided.

@tmancey tmancey added this to New issues in Ads via automation May 21, 2021
@tmancey tmancey moved this from New issues to Backlog in Ads May 21, 2021
@tmancey tmancey self-assigned this May 21, 2021
@tmancey tmancey added priority/P3 The next thing for us to work on. It'll ride the trains. release-notes/exclude QA/Yes labels Jun 10, 2021
@tmancey tmancey moved this from Backlog to In progress in Ads Jun 22, 2021
@tmancey tmancey moved this from In progress to Review in Ads Sep 15, 2021
@tmancey tmancey moved this from Review to In progress in Ads Sep 15, 2021
@jsecretan
Copy link

Sizing at 2 points

@jsecretan jsecretan added the 2_point For Agile sizing label Oct 5, 2021
@jsecretan jsecretan added 1_point For Agile sizing and removed 2_point For Agile sizing labels Nov 2, 2021
@tmancey tmancey moved this from In progress to Review in Ads Nov 9, 2021
@tmancey tmancey added OS/Android Fixes related to Android browser functionality OS/iOS Fixes related to iOS browser functionality labels Dec 9, 2021
Ads automation moved this from Review to Done Dec 9, 2021
@tmancey tmancey added this to the 1.35.x - Nightly milestone Dec 9, 2021
@GeetaSarvadnya GeetaSarvadnya added the QA/In-Progress Indicates that QA is currently in progress for that particular issue label Jan 12, 2022
@GeetaSarvadnya
Copy link
Collaborator

GeetaSarvadnya commented Jan 12, 2022

Verification PASSED on

Brave | 1.35.77 Chromium: 97.0.4692.71 (Official Build) beta (64-bit)
-- | --
Revision | adefa7837d02a07a604c1e6eff0b3a09422ab88d-refs/branch-heads/4692@{#1247}
OS | Windows 10 Version 21H2 (Build 19044.1415)

Verified the test plan from brave/brave-core#10956

Case 1: Verify user is only rewarded if ads are enabled_PASSED
  • Confirmed ads are served when rewards/ads are enabled
  • Confirmed users are rewarded for viewed ads
  • Confirmed ads earnings are displayed in the Ads panel in brave://rewards
  • Confirmed ads notification count is shown correctly in Ads panel in brave://rewards
  • Confirmed ads notification count and ads earnings are retained in ads panel after browser restart
  • Confirmed ads earnings are shown in NTP
  • Confirmed ads earnings are retained in the NTP after browser restart
Example Example
image image

Serving ad notification:

[15676:7504:0113/114653.261:VERBOSE1:ad_notification_serving.cc(260)] Serving ad notification:
  uuid: 02f8cf06-8b54-40df-92b0-2cd1f738556c
  creativeInstanceId: 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4
  creativeSetId: 2003f580-4703-408a-aab4-881230aa4a6c
  campaignId: 9bb85ea3-f510-4047-8cbb-4ba40fe3e84d
  advertiserId: 93130af3-2def-4ecb-b836-b3772e73b3c9
  segment: untargeted
  title: Verifiable Ad Conversion - URL
  body: Test VAC - VAC ID from URL parameter
  targetUrl: https://www.nytimes.com
[15676:7504:0113/114653.271:INFO:notification_helper_win.cc(187)] Notifications are enabled
[15676:7504:0113/114653.272:INFO:notification_helper_win.cc(154)] Focus Assist is disabled
[15676:7504:0113/114653.273:VERBOSE1:ads_service_impl.cc(1912)] Timeout ad notification with uuid 02f8cf06-8b54-40df-92b0-2cd1f738556c in 120 seconds
[15676:7504:0113/114653.277:VERBOSE3:ad_notification_event_served.cc(24)] Served ad notification with uuid 02f8cf06-8b54-40df-92b0-2cd1f738556c and creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4
[15676:7504:0113/114653.278:VERBOSE1:ad_notification_serving.cc(153)] Served ad notification
[15676:7504:0113/114653.279:VERBOSE3:ad_notification_event_viewed.cc(24)] Viewed ad notification with uuid 02f8cf06-8b54-40df-92b0-2cd1f738556c and creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4
[15676:7504:0113/114653.287:VERBOSE1:ad_notification_event_served.cc(32)] Successfully logged ad notification served event
[15676:7504:0113/114653.300:VERBOSE6:ad_notification_event_viewed.cc(32)] Successfully logged ad notification viewed event
Case 2: Verify users are rewarded after viewing an ad_PASSED
  • Confirmed x amount of BAT is assigned after viewing an Ad

Assigning x amount of BAT for viewed ad

[15676:7504:0113/114653.315:VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4 and view valued at 0.01
[15676:7504:0113/114653.315:VERBOSE1:confirmations.cc(69)] Confirming view for ad_notification with transaction id 8de6fed2-c435-4264-8d3d-71ae364f09a5 and creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4
Case 3: Verify confirmations are sent to the backend_PASSED
  • Confirmed new table Transactions is been added to DB
  • Confirmed confirmation type events are other details are stored in the Transactions table
    image
Case 4: Verify ads are added to 30-day Ads History_PASSED
  • Confirmed ads are added to 30 days ads history
    image
Case 5: Verify 30-day Ads History is showing ads for the last 30-days_PASSED
  • Confirmed ads history is showing ads for last 30 days
Example Example
image image
Case 6: Verify current earnings this month (estimated) has the correct value_PASSED
  • Confirmed current earnings this month is showing up the correct value
Example Example
image image
Case 7: Verify current earnings this month (estimated) is updated when a user resets Rewards_PASSED
  • Confirmed current earnings this month (estimated) is updated after rewards reset
    Before reset | After reset
    -----|----
    image | image
Case 8: Verify "Next payment date" shows the correct value_PASSED
  • Confirmed Next payment date shows the correct value (next payment date is shown based on the griffin configuration)
  • Browser restart is required to pick the correct next payment date from the griffin service which is known
    image
Case 9: Verify "Next payment date" is updated when a user resets Rewards_PASSED
  • Viewed 5 Ads and ad notifications and estimated earnings are displayed correctly in Ads panel
  • Next payment date is displayed as 7th as expected
  • Go to brave://settings/clearBrowserData and Reset rewards
  • Re-enable rewards via BR panel
  • Confirmed next payment date is reset as expected
Next payment date before rewards reset Next payment date after rewards reset
image image
Case 10: Verify "Ads received this month" has the correct value_PASSED
  • Confirmed Ads received this month works as expected
Example Example
image image
Case 11: Verify "Ads received this month" is updated when a user resets Rewards_PASSED
  • Viewed 4 Ads and confirmed "Ads received this month" is displayed as expected
  • Reset the rewards and Re-enable rewards via BR panel
  • Confirmed "Ads received this month" is reset to zero
Ads received this month before rewards reset Ads received this month after rewards reset
image image
Case 12: Verify Rewards widget "Earnings" has the correct value_PASSED
  • Testing is covered in case 1 and case 2
Case 13: Verify Rewards widget "Earnings" is updated when a user resets Rewards_PASSED
  • Viewed an Ad and confirmed Ads earning is shown in the NTP widget
  • Reset the rewards and Re-enable rewards via BR panel
  • Confirmed "Ads received this month" is reset to zero in NTP widget
Ads panel before rewards reset NTP Rewards widget before rewards reset
image image
Ads panel before rewards reset NTP Rewards widget before rewards reset
image image
Case 14: Verify Rewards panel "Estimated Earnings" has the correct value_PASSED
  • Testing is covered in case 1 and case 2
Case 15: Verify Rewards panel "Estimated Earnings" is updated when a user resets Rewards_PASSED
  • Viewed a couple of ads and confirmed Estimated earning is displayed as expected in Ads panel
  • Reset the rewards and Re-enable rewards via BR panel
  • Confirmed Estimated earning is reset to zero
Estimated earning before rewards reset Estimated earning after rewards reset
image image
Case 16: Verify Rewards are reset to 0.0 (plus any rewards which were not cashed-in) at midnight on the 1st of each month based on the users local time_PASSED

Case 1:

  1. Clean profile 1.35.x and enable rewards
  2. View a few NTP SI and a regular Ad today (31st Jan)
  3. Close the browser
    image (5)
  4. Confirmed 4 NTP SI and 1 regular Ad, estimated rewards is shown as expected in the UI (NTP SI (0.05x4 = 0.020) Regular ad (0.05x1=0.05, Total 0.025BAT)
  5. Reconcile the ads with server by adding a time which is 2 mins ahead of current time (Epoch converter time) in Preference file and save the preference file
  6. Relaunch the browser and wait for 2 mins to elapse and confirmed ads are reconciled with server
  7. Move the system clock to 11.59 PM 31st Jan
  8. Relaunch the browser
  9. Wait for 1 min to elapse so that you can see 1st Feb 2021 in the system clock
  10. Reload brave://rewards page
    image (7)
  11. Confirmed estimated rewards and ad notification is reset to zero as expected
  12. Confirmed All the ads (NTP SI + Regular ad) are reconciled with the server in DB hence estimated pending rewards is 0.0
    image (8)
  13. Confirmed previous month pending payment arriving message is shown as expected and correct
Case 17: Verify "Your +#.# BAT payout will begin processing in # day." is working as expected_PASSED
Case 18: Verify unblinded payment tokens are removed from confirmations.json when a user resets Rewards_PASSED
  • Clean profile 1.35.x
  • Enable rewards and view an Ad
  • Confirmed that unblinded payment tokens are redeunemed for Click and View event
  • Open Confirmation.json file and confirm unblinded_payment_tokens array has two unblinded payment token for click and view event
  • Confirmed that 48 unblinded tokens are leftover in the unblinded_tokens array in confirmation.json file
  • Reset the rewards via brave://settings/clearBrowserData
  • Enable rewards and close the browser immediately before 50 unblinded tokens refill
  • Open confirmation.json file and confirmed unblinded payment tokens are removed from confirmation.json file, both unblinded_payment_tokens and unblinded_tokens are empty after resetting rewards
{"confirmations":{"failed_confirmations":[]},"issuers":[{"name":"payments","publicKeys":[{"associatedValue":"0.3","publicKey":"1k/s72Bt/EALh21SYY3cA/moIJNRTPup5Aoor51jhAA="},{"associatedValue":"0.1","publicKey":"7r0YfIwSriuAZ9Vnu7cqnxEeYRptV3CFXA+havx9yw8="},{"associatedValue":"0.2","publicKey":"9t4cxKQ+tfozUtYs2YnruTmd76UK4j0asdf4GxGtm2U="},{"associatedValue":"0.01","publicKey":"BO81+2Db6pEgReNmOWCTqIgQulhkKyyBA0Bzb4hPYF8="},{"associatedValue":"0.01","publicKey":"GOB6LeHg+z3Li9T5nWPdbVpGPLZ3mQm25h/KnPPIpEI="},{"associatedValue":"0.025","publicKey":"IowiaDyv8o+sKQc3bxJH3/0VEUz47PKu/VgrrPoeAVc="},{"associatedValue":"0.025","publicKey":"JJRSEd/ujNhDU/5dgFIzcy/J5qZ19CcQr7FFIWnhfCo="},{"associatedValue":"0.05","publicKey":"JhjKLoBpYtgoLHeEsKnYwv/3iqOEWZ9yHVvh5TEn0i4="},{"associatedValue":"0","publicKey":"KAQtJ7UMbE+EEp92j6e5Q7yzcK4bj/+281hqlFO0R1I="},{"associatedValue":"0.15","publicKey":"LhRQAbJMXXZK/T/qSLBhq5IktOpM0hD3BF/0MdLZljY="},{"associatedValue":"0.15","publicKey":"QJOgNxS5yykuKOhutY3NIG1hrHHQNx7qm0WmUnZsUhU="},{"associatedValue":"0.3","publicKey":"VgwQIan/Hfiu5PCTXmp5KWGATRMK84ykG1bPVv3IGSg="},{"associatedValue":"0.25","publicKey":"ZvzeYOT1geUQXfOsYXBxZj/H26IfiBUVodHl51j68xI="},{"associatedValue":"0","publicKey":"bsc5+phOJ4Ag3NwK1qHQNFVWr2glbPMDU0T+g26u3gE="},{"associatedValue":"0.05","publicKey":"eAquUTx5WevwJXUBtD9Mz1fnP5ujEPsx+ghTteDUQzI="},{"associatedValue":"0.25","publicKey":"euTO5ufArBqD6SJSAVYMSC1HLCnRWwiwMgORSgBUSjI="},{"associatedValue":"0.1","publicKey":"qC0nPobDx4kDUpoH4VknpTGqqjPqmUtmSsNPrCXzBSg="},{"associatedValue":"0.2","publicKey":"vHFyNcUPdslbZXUw3nTg1GwPloza/Cc5WYJ1QjFisCE="}]},{"name":"confirmations","publicKeys":[{"associatedValue":"0","publicKey":"8ESBHy92G+fCRivLc4IAy+HTVNF+egtKgyiP3Qt5yH0="},{"associatedValue":"0","publicKey":"CAN2pvKdmlOsibN+8H2dtzYP+rXmdCwYCSZdGliF7HA="}]}],"unblinded_payment_tokens":[],"unblinded_tokens":[]}

Additional testing:

  1. Enabled Ads/rewards and confirmed ads are initialized and 50 unblinded tokens are refilled
[16900:15988:0127/214141.706:VERBOSE1:refill_unblinded_tokens.cc(187)] OnGetSignedTokens
[16900:15988:0127/214141.706:VERBOSE6:refill_unblinded_tokens.cc(189)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v2/confirmation/token/e07f1361-6e56-4565-a684-3001ec99d36c?nonce=39416ef9-dbed-4472-8890-8a09fa2e57a9
  Response Status Code: 200
  Response: {"batchProof":"gBPEmMn4.....
[16900:15988:0127/214141.736:VERBOSE1:refill_unblinded_tokens.cc(323)] Added 50 unblinded tokens, you now have 50 unblinded tokens
[16900:15988:0127/214141.738:VERBOSE1:account.cc(293)] Successfully refilled unblinded tokens
  1. Viewed an Ad and confirmed users are rewarded for Ads view event
[16900:15988:0127/214909.720:VERBOSE1:ad_notification_serving.cc(260)] Serving ad notification:
  uuid: d45570d1-61e9-4f4c-96e5-cfb4b9fbadd3
  creativeInstanceId: faec6d5b-9e30-45a5-8420-3435abe1695a
  creativeSetId: 45ea5952-37ca-41f0-88c2-4b546b0e6f4b
  campaignId: 1c1ac828-db13-49bb-9128-090132044b7f
  advertiserId: ecbcc833-8b1d-4867-98f7-ad2341396ce8
  segment: untargeted
  title: Ad6
  body: Ad6
  targetUrl: https://brave.com
[16900:15988:0127/214909.728:INFO:notification_helper_win.cc(187)] Notifications are enabled
[16900:15988:0127/214909.728:INFO:notification_helper_win.cc(154)] Focus Assist is disabled
[16900:15988:0127/214909.728:VERBOSE1:ads_service_impl.cc(1912)] Timeout ad notification with uuid d45570d1-61e9-4f4c-96e5-cfb4b9fbadd3 in 120 seconds
[16900:15988:0127/214909.759:VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id faec6d5b-9e30-45a5-8420-3435abe1695a and view valued at 0.01
  1. Confirmed Timeout ad notification is 120 secs (2 mins)
[16900:15988:0127/214909.728:VERBOSE1:ads_service_impl.cc(1912)] Timeout ad notification with uuid d45570d1-61e9-4f4c-96e5-cfb4b9fbadd3 in 120 seconds
  1. View an Ad, out of 50 unblinded tokens 1 token is redeemed for View and 1 token for the Click event
[16900:15988:0127/214935.322:VERBOSE1:confirmations.cc(284)] Successfully redeemed unblinded token for ad_notification with confirmation id 5a5dd9f0-8359-428b-9fb3-4fcac037a9c8, transaction id 26a63055-60c7-4742-968b-187652a3586e, creative instance id faec6d5b-9e30-45a5-8420-3435abe1695a and click.

[16900:15988:0127/214914.951:VERBOSE1:confirmations.cc(284)] Successfully redeemed unblinded token for ad_notification with confirmation id 5eafe09a-4244-4bdb-93f9-6af4cb9c0323, transaction id 26d19400-e9bf-4ac9-8697-3c8d202d76aa, creative instance id faec6d5b-9e30-45a5-8420-3435abe1695a and view.
  1. Confirmed 48 unblinded tokens remained in Confirmation.json file
[16900:15988:0127/214914.956:VERBOSE1:refill_unblinded_tokens.cc(84)] No need to refill unblinded tokens as we already have 48 unblinded tokens which is above the minimum threshold of 20
Case 19: Verify failed confirmations are removed from confirmations.json when a user resets Rewards_PASSED

Additional testing:

  • Confirmed failed confirmations are retried and processed successfully when the rewrite rule is disabled in the Charles
  • Confirmed failed confirmation queue becomes empty once all the failed confirmations are retried and processed
  • Confirmed Successfully redeemed unblinded token... logs are shown for both View and Click events
[8300:11084:0127/205528.684:VERBOSE1:confirmations.cc(284)] Successfully redeemed unblinded token for ad_notification with confirmation id 4fd5ed3d-0162-4cb1-9044-cd3f3dbdaffa, transaction id b746f8b1-3195-4167-8a32-38440378cd6f, creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4 and view.

[8300:11084:0127/205525.280:VERBOSE1:confirmations.cc(284)] Successfully redeemed unblinded token for ad_notification with confirmation id e1b56be6-6ccb-4bc9-a649-7a4098102d37, transaction id 7e48e66b-03ff-4b66-8390-3d8ab3649714, creative instance id 0e3fa44c-edd4-4ad3-b21e-e6c93ef001c4 and click.
Case 20: Verify transactions are removed from database.sqlite when a user resets Rewards_PASSED
  • Viewed 4 ads and transactions are stored in the Transactions table
  • Reset Rewards and Re-enable rewards via BR panel
  • Confirmed that transactions are removed from the Transactions table after rewards reset
Transactions table before rewards reset Transactions table after rewards reset
image image
Case 21: Verify transactions are migrated from confirmations.json to a new transactions table in database.sqlite_PASSED
  • Confirmed new table Transactions is been added to DB
  • Confirmed confirmation type events are other details are stored in the Transactions table
    image
Case 22: Verify transactions are added to transactions table in database.sqlite_PASSED
  • Confirmed new table Transactions is been added to DB
  • Confirmed confirmation type events are other details are stored in the Transactions table
    image
Case 23: Verify redeemed_at column for the 'transactions' table in database.sqlite is updated for cashed-out tokens_PASSED
  • Not sure which row is referring to cashed out tokens could be reconciled_at asked clarification to @tmancey - @tmancey clarified reconciled_at = cashed out tokens
    image
Case 24: Verify next_token_redemption_date_in_seconds is migrated from confirmations.json to brave.brave_ads.rewards.next_time_redemption_at pref_PASSED
  • Confirmed next_token_redemption_date_in_seconds is migrated from confirmations.json to preference file
  • Confirmed next_time_redemption_at is present in the preference file
    image
Case 25: Verify next token redemption date is working as expected_PASSED
  • Viewed a couple of ads and closed the browser
  • Updated the next_time_redemption_at (Preference file) with Epoch timestamp and save the preference file
  • Relaunch the browser and wait for Epoch timestamp to elapse
  • Confirmed unblinded tokens are redeemed with the server successfully
[8596:1532:0113/160449.071:VERBOSE1:redeem_unblinded_payment_tokens.cc(113)] OnRedeemUnblindedPaymentTokens
[8596:1532:0113/160449.072:VERBOSE6:redeem_unblinded_payment_tokens.cc(115)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v2/confirmation/payment/7a044a4d-9803-43d0-b45f-f0655fade462
  Response Status Code: 200
  Response: {"response":"Ok","status":200,"message":"Ok"}
[8596:1532:0113/160449.074:VERBOSE1:account.cc(272)] Successfully redeemed unblinded payment tokens
[8596:1532:0113/160449.082:VERBOSE1:redeem_unblinded_payment_tokens.cc(74)] Redeem unblinded payment tokens on Saturday, January 15, 2022 at 11:31:00 PM
[8596:1532:0113/160449.089:VERBOSE3:account.cc(281)] Successfully updated transactions
Case 26: Verify day parting frequency cap is working as expected_ PASSED

Prerequisites: To test this scenario created a custom catalog that has a dayParting block that contains the start minute, end minute, and dow (Day of the week) parameters, if we mention the specified time in the start min, end min and particular day in the dow parameter, ads should be triggered within that time period. If the specified time elapses then ads should not be triggered.

Case1: Test that ads are served in the specific time frame and day_PASSED
  • Confirmed ads are shown within the dayPartings specified time frame and day
  • Confirmed estimated ad earnings and ad notification count is shown as expected in the ads panel
  • Confirmed logs are shown as expected
  • Confirmed ads are not shown when the dayParting start and end min elapses

dayParting parameters:

"dayParts": [
        {
          "dow": "3",
          "endMinute": 1050,
          "startMinute": 1020
        },
        {
          "dow": "123",
          "endMinute": 1050,
          "startMinute": 1020
        }
      ],
Ist Ad 2nd Ad
image (3) image (3)

Ad serve Logs:

[13916:8868:0202/175031.043:VERBOSE1:ad_notification_serving.cc(260)] Serving ad notification:
  uuid: 45730e02-c403-4ecf-8793-aad5e086592d
  creativeInstanceId: faec6d5b-9e30-45a5-8420-3435abe1695a
  creativeSetId: 45ea5952-37ca-41f0-88c2-4b546b0e6f4b
  campaignId: 1c1ac828-db13-49bb-9128-090132044b7f
  advertiserId: ecbcc833-8b1d-4867-98f7-ad2341396ce8
  segment: untargeted
  title: Test_dayParts_Geeta_Ad6
  body: Ad6
  targetUrl: https://brave.com
[13916:8868:0202/175031.050:INFO:notification_helper_win.cc(187)] Notifications are enabled

[13916:8868:0202/175637.412:VERBOSE1:ad_notification_serving.cc(260)] Serving ad notification:
  uuid: 36a79cbb-ea74-4c66-bfd9-6a5f782a0953
  creativeInstanceId: 2db34507-c654-4302-92ee-7fba4a8bc1fe
  creativeSetId: 45ea5952-37ca-41f0-88c2-4b546b0e6f4b
  campaignId: 1c1ac828-db13-49bb-9128-090132044b7f
  advertiserId: ecbcc833-8b1d-4867-98f7-ad2341396ce8
  segment: untargeted
  title: Test_dayParts_Geeta_Ad9
  body: Ad9
  targetUrl: https://brave.com
[13916:8868:0202/175637.421:INFO:notification_helper_win.cc(187)] Notifications are enabled

Logs when dayParting start and end min elapses

[13916:8868:0202/180254.198:VERBOSE1:eligible_ad_notifications_v1.cc(150)] No eligible ads for untargeted segment
[13916:8868:0202/180254.198:VERBOSE1:ad_notification_serving.cc(136)] Ad notification not served: No eligible ads found
Case2: Test that ads are served in the specific time frame and day_PASSED
  • Confirmed ads are shown within the dayparting specified time frame and day
  • Confirmed ads are not shown when the dayParting start and end min elapses

dayParting parameters:

"dayParts": [
        {
          "dow": "3",
          "endMinute": 1080,
          "startMinute": 1050
        },
        {
          "dow": "123",
          "endMinute": 1080,
          "startMinute": 1050
        }
      ],

Logs when dayParting start and end min elapses

[13916:8868:0202/180254.198:VERBOSE1:eligible_ad_notifications_v1.cc(150)] No eligible ads for untargeted segment
[13916:8868:0202/180254.198:VERBOSE1:ad_notification_serving.cc(136)] Ad notification not served: No eligible ads found
Case 3: Test that ads are NOT served when dayParting start min and end min is set to 0_PASSED
  • Confirmed ads are not served when Start min and end min parameters are set to 0

dayParting parameters:

 "dayParts": [
        {
          "dow": "3",
          "endMinute": 0,
          "startMinute": 0
        },
        {
          "dow": "123",
          "endMinute": 0,
          "startMinute": 0
        }
      ],

_Logs when dayParting start and end min set to 0

[13916:8868:0202/180254.198:VERBOSE1:eligible_ad_notifications_v1.cc(150)] No eligible ads for untargeted segment
[13916:8868:0202/180254.198:VERBOSE1:ad_notification_serving.cc(136)] Ad notification not served: No eligible ads found
Case 4: Test that ads are not served when dayParting start and end mins is same_ PASSED
  • Confirmed ads are not served when Start min and end min parameters are same

dayParting parameters:

 "dayParts": [
        {
          "dow": "3",
          "endMinute": 1110,
          "startMinute": 1110
        },
        {
          "dow": "123",
          "endMinute": 1110,
          "startMinute": 1110
        }
      ],

_Logs when dayParting start and end min are same

[13916:8868:0202/180254.198:VERBOSE1:eligible_ad_notifications_v1.cc(150)] No eligible ads for untargeted segment
[13916:8868:0202/180254.198:VERBOSE1:ad_notification_serving.cc(136)] Ad notification not served: No eligible ads found
Case 5: Test that ads are served as usual when dayparting block is empty_PASSED
  • Confirmed ads are triggered as usual when the dayParting block is removed/empty in the catalog
  • Confirmed ad earnings and notification count is shown as expected
Case 27: Verify upgrade path from 1.34.x to 1.35.x is working as expected_PASSED

Case 1: Ads switch OFF and then Upgrade to 1.35.x -PASSED

  • Installed 1.34.x and viewed a few ads and ensured estimated earnings and ads received count is shown in Ads panel and NTP widget, turn off Ads switch in Ads panel in brave://rewards and then upgrade the profile to 1.35.x and ensured Ads switch is in OFF state and enabled the ads switch and ensured ads data is retained in both ads panel and NTP widget

Case 2: View a couple of Ads and then Upgrade to 1.35.x - PASSED

  • Installed 1.34.x and viewed a few ads and upgraded the profile to 1.35.x and confirmed ads panel data is retained and NTP widget earning is also retained. Restarted the browser couple of times and ensured ads panel data along with NTP widget earning is retained.

Case 3: View an NTP SI and confirm users are rewarded for viewing an NTPSI and ad notification count increased and then upgrade the profile to 1.35.x - FAILED (known issue #13815)

Case 4: View ads and then reset rewards and then upgrade profile to 1.35.x - PASSED

1.34.x 1.35.x 1.35.x 1.35.x
image image image image

@GeetaSarvadnya
Copy link
Collaborator

GeetaSarvadnya commented Jan 28, 2022

No idea how to test the Case 26- Verify day parting frequency cap is working as expected, discussed with @btlechowski he mentioned this got landed without QA involvement. Hence I am skipping the case 26.

cc: @tmancey @LaurenWags

@tmancey
Copy link
Collaborator Author

tmancey commented Jan 28, 2022

@GeetaSarvadnya see original day part ticket brave/brave-core#6893 with tests (day parting is part of the catalog)

@srirambv
Copy link
Contributor

Verification passed on Samsung Tab A with Android 10 running 1.35.98 x64 build

Case 1: Confirm user is only rewarded if ads are enabled - Passed
  • Verified ads are served only when Ads is enabled
  • Verified users are rewarded for viewing ads
  • Verified Current months earning (estimated) is shown in brave://rewards and in panel
  • Verified Ads received this month is shown correctly and increments as and when an ad is shown
  • Verified disabling ads doesn't reset Ads received and Current month earnings
Case 2: Confirm users are rewarded after viewing an ad - Passed
  • Verified x amount of BAT is assigned after view/click/landed or dismissing an Ad

View

2022-01-31 03:13:12.319 23064-23064/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250 and view valued at 0.01
2022-01-31 03:13:12.319 23064-23064/? V/chromium: [VERBOSE1:confirmations.cc(69)] Confirming view for ad_notification with transaction id 9300f808-a925-4c4e-8b88-c0c43d0d14f9 and creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250

Click

2022-01-31 03:13:18.395 23064-23064/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250 and click valued at 0
2022-01-31 03:13:18.395 23064-23064/? V/chromium: [VERBOSE1:confirmations.cc(69)] Confirming click for ad_notification with transaction id 36ef3f09-3942-41d7-95a0-ddbdb0768023 and creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250

Landed

2022-01-31 03:13:30.870 23064-23064/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250 and landed valued at 0
2022-01-31 03:13:30.870 23064-23064/? V/chromium: [VERBOSE1:confirmations.cc(69)] Confirming landed for ad_notification with transaction id c79db5c5-bebd-491d-8ddc-d8232e99402f and creative instance id c6a6b939-4167-41fb-8a84-1edde6c12250

Dismiss

2022-01-31 03:20:29.828 24230-24230/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 4cda3ae7-1f70-4bca-b361-ca01d6a8f1ed and dismiss valued at 0
2022-01-31 03:20:29.828 24230-24230/? V/chromium: [VERBOSE1:confirmations.cc(69)] Confirming dismiss for ad_notification with transaction id 86fb20d6-3c6e-4cf2-aefb-ef2490e1adef and creative instance id 4cda3ae7-1f70-4bca-b361-ca01d6a8f1ed

Case 3: Confirm confirmations are sent to the backend Not testable on Android
  • Can't verify it on the db as there is no access to db files
Case 4: Confirm ads are added to 30-day Ads History - Not testable on Android
Case 5: Confirm 30-day Ads History is showing ads for the last 30-days - Not testable on Android
Case 6: Confirm brave://rewards "Current earnings this month (estimated)" has the correct value - Passed
  • Verified Current earning this month (estimated) shows correct values based on the number of ads seen
    Note: there is no way to verify this by cross-checking the transaction tables in db as Android doesn't provide access to it
Ads settings Panel
image image
Case 7: Confirm brave://rewards "Current earnings this month (estimated)" is updated when a user resets Rewards - Failed
  • Verification failed as reset rewards on Android doesn't work correctly which is a known issue #8776
Case 8: Confirm brave://rewards "Next payment date" shows the correct value - Passed
  • Verified Next payment date shows the correct value (next payment date is shown based on the griffin configuration)
  • Browser restart is required to pick the correct next payment date from the griffin service which is known
Case 9: Confirm brave://rewards "Next payment date" is updated when a user resets Rewards - Failed
  • Verification failed as reset rewards on Android doesn't work correctly which is a known issue #8776
Case 10: Confirm brave://rewards "Ads received this month" has the correct value - Passed
  • Verified Ads received this month shows the correct values based on ads received
Case 11: Confirm brave://rewards "Ads received this month" is updated when a user resets Rewards - Failed
  • Verification failed as reset rewards on Android doesn't work correctly which is a known issue #8776
Case 12: Confirm Rewards widget "Earnings" has the correct value - Not Applicable for Android
Case 13: Confirm Rewards widget "Earnings" is updated when a user resets Rewards - Failed on reset and Not Applicable on Android for widget
Case 14: Confirm Rewards panel "Estimated Earnings" has the correct value - Passed
  • Verified as part of Case 1 & Case 2
Case 15: Confirm Rewards panel "Estimated Earnings" is updated when a user resets Rewards - Failed
  • Verification failed as reset rewards on Android doesn't work correctly which is a known issue #8776
Case 16: Confirm Rewards are reset at midnight on the 1st of each month based on the users local time to the total amount of unreconciled transactions for previous months (i.e. carried over) - Partial Passed
  • Verified rewards is reset on midnight of the 1st of each month
  • Set Date to 31st Jan and viewed 5 ads (4NTP SI ads and 1 ad notification) totalling to 0.022 BAT
  • Removed brave from memory and set device time to 31 Jan 11.59 PM
  • Waited for the device to move past 12.00 AM of Feb 1
  • Rewards balance was retained but ads viewed this month was reset to 0
  • Waited for an ad notification to show up
  • Ads viewed this month increased by 1 and balance from Jan was carried forward
31st Jan 1st Feb
image image

Encountered #20795

Case 17: Confirm "Your +#.# BAT payout will begin processing in # day." is working as expected- Passed
  • Verified rewards is reset on midnight of the 1st of each month
  • Set Date to 31st Jan and viewed 5 ads (4NTP SI ads and 1 ad notification) totalling to 0.022 BAT
  • Removed brave from memory and set device time to 31 Jan 11.59 PM
  • Waited for the device to move past 12.00 AM of Feb 1
  • Restarted the browser and closed it again
  • Moved date forward to Feb 3
  • Restarted the browser and opened ads details page and saw the Your # BAT payout will begin processing in # days message
Light Theme Dark Theme
image image
Case 18: Confirm unblinded payment tokens are removed from confirmations.json when a user resets Rewards - Not testable on Android
Case 19: Confirm failed confirmations are removed from confirmations.json when a user resets Rewards - Not testable on Android
  • Can't update/view confirmations.json file on Android but did confirm Successfully redeemed unblinded token... logs are shown for both View/Click/Landed and Dismissed events as mentioned in Case 2
Case 20: Confirm transactions are removed from database.sqlite when a user resets Rewards - Not testable on Android
  • Can't view transactions table in db and rewards reset fails due to #8776
Case 21: Confirm transactions are migrated from confirmations.json to a new transactions table in database.sqlite - Not testable on Android
  • Can't view transactions table in db
Case 22: Confirm transactions are added to transactions table in database.sqlite - Not testable on Android
  • Can't view transactions table in db
Case 23: Confirm redeemed_at column for the 'transactions' table in database.sqlite is updated for cashed-out tokens - Not testable on Android
  • Can't view transactions table in db
Case 24: Confirm next_token_redemption_date_in_seconds is migrated from confirmations.json to brave.brave_ads.rewards.next_time_redemption_at pref - Not testable on Android
Case 25: Confirm next token redemption date is working as expected - Not testable on Android
  • Can't edit preferences file
Case 26: Confirm day parting frequency cap is working as expected - Not testable on Android
Case 27: Confirm upgrade path from 1.34.x to 1.35.x is working as expected - Partial Passed

Case 1: Ads switch OFF and then Upgrade to 1.35.x -PASSED

  • Installed 1.34.81 and viewed a few ads
  • Turned off Ads
  • Upgraded to 1.35.98 and ensured Ads remained turned off
  • Verified when enabled, estimated ads earnings was retained
16028-Case1.mp4

Case 2: View a couple of Ads and then Upgrade to 1.35.x - PASSED

  • Installed 1.34.81 and viewed a few ads
  • Upgraded to 1.35.98
  • Verified estimated ads earnings and total viewed ads are retained
  • Verified new BR panel shows the estimated earnings and match with rewards page
16028-Case2.mp4

Case 3: View an NTP SI and confirm users are rewarded for viewing an NTPSI and ad notification count increased and then upgrade the profile to 1.35.x -PASSED

  • Verified opening a new tab page with SI is both served and viewed events are captured
2022-01-31 06:20:50.769 6443-6443/? V/chromium: [VERBOSE3:new_tab_page_ad_event_viewed.cc(23)] Viewed new tab page ad with uuid cfacb757-416c-4042-b90e-20cbb0f93a42 and creative instance id 415254ef-6ced-40bd-8f5e-e202c69511ca
2022-01-31 06:20:50.770 6443-6443/? V/chromium: [VERBOSE1:confirmations.cc(93)] Confirming view for creative instance id 415254ef-6ced-40bd-8f5e-e202c69511ca
2022-01-31 06:20:50.798 6443-6443/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(53)] Redeem unblinded token
2022-01-31 06:20:50.799 6443-6443/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(67)] CreateConfirmation
2022-01-31 06:20:50.799 6443-6443/? V/chromium: [VERBOSE2:redeem_unblinded_token.cc(68)] POST /v1/confirmation/{confirmation_id}/{credential}
2022-01-31 06:20:50.799 6443-6443/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(72)] URL Request:
      URL: https://ads-serve.brave.com/v1/confirmation/282f3c22-9108-4cfd-87ed-117081bc61c7/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiZEhqTVU0RFRySHF0WUttUHhoOHVvbmoyTElNckJBeEV0eFJsMnRzZ0V3Yz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwicmVsZWFzZVwiLFwiY291bnRyeUNvZGVcIjpcIklOXCIsXCJjcmVhdGl2ZUluc3RhbmNlSWRcIjpcIjQxNTI1NGVmLTZjZWQtNDBiZC04ZjVlLWUyMDJjNjk1MTFjYVwiLFwicGF5bG9hZFwiOnt9LFwicGxhdGZvcm1cIjpcImFuZHJvaWRcIixcInN0dWRpZXNcIjpbXSxcInR5cGVcIjpcInZpZXdcIn0iLCJzaWduYXR1cmUiOiJQOUVyTC9kVXVYZTh1Y1VqcXVzWldoSGZseFFVUEJ2cGF3elVpbitEZzlVY040dVozVFVPZll3WXQxMXhLL2hQSmMzVEMxVVhkaWJxVGREVU1LNWtUUT09IiwidCI6IkNXcWk2cUhpaEhLTUxZQkFkTTNMaGhxVThYQVprT3EyUkxXemtQSVZEd0pnOUQ3NDEzOGdMTi8xbytycXh4UlFlZG1LUGFkL3F5OE4zV2hiSjRoeDRRPT0ifQ==
      Content: {"blindedPaymentToken":"dHjMU4DTrHqtYKmPxh8uonj2LIMrBAxEtxRl2tsgEwc=","buildChannel":"release","countryCode":"IN","creativeInstanceId":"415254ef-6ced-40bd-8f5e-e202c69511ca","payload":{},"platform":"android","studies":[],"type":"view"}
      Content Type: application/json
      Method: kPost
2022-01-31 06:20:50.800 6443-6443/? V/chromium: [VERBOSE6:new_tab_page_ad_event_viewed.cc(31)] Successfully logged new tab page ad viewed event
2022-01-31 06:20:50.806 6443-6443/? V/chromium: [VERBOSE3:new_tab_page_ad_event_served.cc(23)] Served new tab page ad with uuid cfacb757-416c-4042-b90e-20cbb0f93a42 and creative instance id 415254ef-6ced-40bd-8f5e-e202c69511ca
2022-01-31 06:20:50.819 6443-6443/? V/chromium: [VERBOSE6:new_tab_page_ad_event_served.cc(31)] Successfully logged new tab page ad served event
2022-01-31 06:20:51.128 6443-6443/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(83)] OnCreateConfirmation
2022-01-31 06:20:51.128 6443-6443/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(85)] URL Response:
      URL: https://ads-serve.brave.com/v1/confirmation/282f3c22-9108-4cfd-87ed-117081bc61c7/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiZEhqTVU0RFRySHF0WUttUHhoOHVvbmoyTElNckJBeEV0eFJsMnRzZ0V3Yz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwicmVsZWFzZVwiLFwiY291bnRyeUNvZGVcIjpcIklOXCIsXCJjcmVhdGl2ZUluc3RhbmNlSWRcIjpcIjQxNTI1NGVmLTZjZWQtNDBiZC04ZjVlLWUyMDJjNjk1MTFjYVwiLFwicGF5bG9hZFwiOnt9LFwicGxhdGZvcm1cIjpcImFuZHJvaWRcIixcInN0dWRpZXNcIjpbXSxcInR5cGVcIjpcInZpZXdcIn0iLCJzaWduYXR1cmUiOiJQOUVyTC9kVXVYZTh1Y1VqcXVzWldoSGZseFFVUEJ2cGF3elVpbitEZzlVY040dVozVFVPZll3WXQxMXhLL2hQSmMzVEMxVVhkaWJxVGREVU1LNWtUUT09IiwidCI6IkNXcWk2cUhpaEhLTUxZQkFkTTNMaGhxVThYQVprT3EyUkxXemtQSVZEd0pnOUQ3NDEzOGdMTi8xbytycXh4UlFlZG1LUGFkL3F5OE4zV2hiSjRoeDRRPT0ifQ==
      Response Status Code: 201
      Response: {"id":"282f3c22-9108-4cfd-87ed-117081bc61c7","payload":{},"createdAt":"2022-01-31T11:20:50.936Z","type":"view","modifiedAt":"2022-01-31T11:20:50.936Z","creativeInstanceId":"415254ef-6ced-40bd-8f5e-e202c69511ca"}

Case 4: View ads and then reset rewards and then upgrade profile to 1.35.x - Failed

  • Failed due to known issue with reset rewards #8776

@GeetaSarvadnya
Copy link
Collaborator

GeetaSarvadnya commented Feb 1, 2022

Verification is PASSED on Vivo X70 Pro with Android 11 running 1.35.98 x64 build

Case 1: Confirm user is only rewarded if ads are enabled - Passed
  • Verified ads are served only when Ads is enabled
  • Verified users are rewarded for viewing ads
  • Verified Current months earning (estimated) is shown in brave://rewards and in panel
  • Verified Ads received this month is shown correctly and increments as and when an ad is shown
  • Verified disabling ads doesn't reset Ads received and Current month earnings
Case 2: Confirm users are rewarded after viewing an ad - Passed
  • Verified x amount of BAT is assigned after view/click/landed or dismissing an Ad

Verify ads served logs:

2022-02-01 18:01:39.985 23229-23229/? V/chromium: [VERBOSE1:ad_notification_serving.cc(260)] Serving ad notification:
      uuid: 09572fd3-341a-441b-b298-3d3eb7d925a7
      creativeInstanceId: 10b8a8c1-4308-40f5-b6df-5281cf5ef628
      creativeSetId: 45ea5952-37ca-41f0-88c2-4b546b0e6f4b
      campaignId: 1c1ac828-db13-49bb-9128-090132044b7f
      advertiserId: ecbcc833-8b1d-4867-98f7-ad2341396ce8
      segment: untargeted
      title: Ad1
      body: Ad1
      targetUrl: *****************
2022-02-01 18:01:40.011 23229-23229/? V/chromium: [VERBOSE3:ad_notification_event_served.cc(24)] Served ad notification with uuid 09572fd3-341a-441b-b298-3d3eb7d925a7 and creative instance id 10b8a8c1-4308-40f5-b6df-5281cf5ef628
2022-02-01 18:01:40.012 23229-23229/? V/chromium: [VERBOSE1:ad_notification_serving.cc(153)] Served ad notification

Verify Click event:

2022-02-01 18:01:43.143 23229-23229/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 10b8a8c1-4308-40f5-b6df-5281cf5ef628 and click v

Verify View event:

2022-02-01 18:01:40.054 23229-23229/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 10b8a8c1-4308-40f5-b6df-5281cf5ef628 and view valued at 0.01

Verify Landed event:

2022-02-01 18:01:54.498 23229-23229/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 10b8a8c1-4308-40f5-b6df-5281cf5ef628 and landed valued at 0

Verify Dismissed event:

2022-02-01 18:13:16.117 23229-23229/? V/chromium: [VERBOSE3:ads_impl.cc(762)] Successfully deposited funds for ad_notification with creative instance id 4cda3ae7-1f70-4bca-b361-ca01d6a8f1ed and dismiss valued at 0

Case 6: Confirm brave://rewards "Current earnings this month (estimated)" has the correct value - Passed
  • Verified Current earning this month (estimated) shows correct values based on the number of ads seen
    Note: there is no way to verify this by cross-checking the transaction tables in db as Android doesn't provide access to it
Ads settings Panel
Screenshot_20220201_181655 Screenshot_20220201_181647
Case 8: Confirm brave://rewards "Next payment date" shows the correct value - Passed
  • Verified Next payment date shows the correct value (next payment date is shown based on the griffin configuration)
  • Browser restart is required to pick the correct next payment date from the griffin service which is known
    Screenshot_20220201_181655
Case 10: Confirm brave://rewards "Ads received this month" has the correct value - Passed
  • Verified Ads received this month shows the correct values based on ads received
    Screenshot_20220201_181655
Case 14: Confirm Rewards panel "Estimated Earnings" has the correct value - Passed
  • Verified as part of Case 1 & Case 2
Case 16: Confirm Rewards are reset at midnight on the 1st of each month based on the users local time to the total amount of unreconciled transactions for previous months (i.e. carried over) - Passed
  • View could of ads today (1st Feb 2022)
  • Confirm estimated ads earnings and notification count is shown as expected
  • Confirm both ads are reconciled with the server
  • Set the device date and time to 28th Feb at 11:59 PM
  • Wait for 1 min so that the device date and time change to 1st March 12:00 AM
  • Reload the brave://rewrads page
  • Confirmed payment pending message is shown as expected in Ads panel
  • Confirmed previous month's ad earnings and notification count is reset to 0.0 as expected
28th Feb at 11:59 PM 1st March 12:00 AM
Screenshot_20220228_235917 Screenshot_20220301_000219
Case 17: Confirm "Your +#.# BAT payout will begin processing in # day." is working as expected- Passed

Case 1: Verify count down message

  • View could of ads today (1st Feb 2022)
  • Confirm estimated ads earnings and notification count is shown as expected
  • Confirm both ads are reconciled with the server and close the browser
  • Set the device date to March 1st 2022
  • Relaunch the browser
  • Reload the brave://rewrads page
  • Confirmed payment pending message is shown as expected in Ads panel
  • Confirmed payment pending message start showing up from 1st March to 7th March which is expected as March 8th is the next payment date

Case 2: Verify payment arriving message

  • View could of ads today (1st Feb 2022)
  • Confirm estimated ads earnings and notification count is shown as expected
  • Confirm both ads are reconciled with the server and close the browser
  • Set the device date to March 8th 2022
  • Relaunch the browser
  • Reload the brave://rewrads page
  • Confirmed payment pending message is shown as expected in Ads panel
  • Confirmed payment pending message start showing up from 8th March to 11th March which is expected as March 8th is the next payment date
  • Confirmed no messages are shown on 12th march
Arriving message payment pending message
Screenshot_20220308_185922 Screenshot_20220301_000219
Case 27: Confirm upgrade path from 1.34.x to 1.35.x is working as expected - Passed

Case 1: Ads switch OFF and then Upgrade to 1.35.x -PASSED

  • Installed 1.34.81 and viewed a few ads
  • Turned off Ads
  • Upgraded to 1.35.98 and ensured Ads remained turned off
  • Verified when enabled, estimated ads earnings was retained
Screenrecording_20220201_192735.mp4

Case 2: View a couple of Ads and then Upgrade to 1.35.x - PASSED

  • Installed 1.34.81 and viewed a few ads
  • Upgraded to 1.35.98
  • Verified estimated ads earnings and total viewed ads are retained
  • Verified new BR panel shows the estimated earnings and match with rewards page
Screenrecording_20220201_194033.mp4

Case 3: View an NTP SI and confirm users are rewarded for viewing an NTPSI and ad notification count increased and then upgrade the profile to 1.35.x -PASSED

  • Verified opening a new tab page with SI is both served and viewed events are captured
2022-02-01 19:45:28.612 24385-24385/? V/chromium: [VERBOSE3:new_tab_page_ad_event_viewed.cc(23)] Viewed new tab page ad with uuid 392c30df-6a94-4ff4-ba7d-61c769bb784a and creative instance id 51354073-1525-4756-b97d-6a21f8946d65
2022-02-01 19:45:28.613 24385-24385/? V/chromium: [VERBOSE1:confirmations.cc(93)] Confirming view for creative instance id 51354073-1525-4756-b97d-6a21f8946d65
2022-02-01 19:45:28.619 24385-24385/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(53)] Redeem unblinded token
2022-02-01 19:45:28.619 24385-24385/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(67)] CreateConfirmation
2022-02-01 19:45:28.619 24385-24385/? V/chromium: [VERBOSE2:redeem_unblinded_token.cc(68)] POST /v1/confirmation/{confirmation_id}/{credential}
2022-02-01 19:45:28.619 24385-24385/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(72)] URL Request:
      URL: *********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************
      Content: {"blindedPaymentToken":"4LpL7Qw4FKCKRB7TlCjVOf417ZV8scr6mAemgMEaoEo=","buildChannel":"release","countryCode":"US","creativeInstanceId":"51354073-1525-4756-b97d-6a21f8946d65","payload":{},"platform":"android","studies":[],"type":"view"}
      Content Type: application/json
      Method: kPost
2022-02-01 19:45:28.619 24385-24385/? V/chromium: [VERBOSE6:new_tab_page_ad_event_viewed.cc(31)] Successfully logged new tab page ad viewed event
2022-02-01 19:45:28.621 24385-24385/? V/chromium: [VERBOSE3:new_tab_page_ad_event_served.cc(23)] Served new tab page ad with uuid 392c30df-6a94-4ff4-ba7d-61c769bb784a and creative instance id 51354073-1525-4756-b97d-6a21f8946d65
2022-02-01 19:45:28.624 24385-24385/? V/chromium: [VERBOSE6:new_tab_page_ad_event_served.cc(31)] Successfully logged new tab page ad served event
2022-02-01 19:45:29.031 24385-24385/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(83)] OnCreateConfirmation
2022-02-01 19:45:29.031 24385-24385/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(85)] URL Response:
      URL: *********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************
      Response Status Code: 201
      Response: {"id":"043e683c-30d9-4ec9-bdcc-b5c6d0634d2e","payload":{},"createdAt":"2022-02-01T14:15:28.929Z","type":"view","modifiedAt":"2022-02-01T14:15:28.929Z","creativeInstanceId":"51354073-1525-4756-b97d-6a21f8946d65"}
2022-02-01 19:45:29.031 24385-24385/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(111)] FetchPaymentToken
2022-02-01 19:45:29.031 24385-24385/? V/chromium: [VERBOSE2:redeem_unblinded_token.cc(112)] GET /v1/confirmation/{confirmation_id}/paymentToken
2022-02-01 19:45:29.031 24385-24385/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(116)] URL Request:
      URL: *********************************************************************************************
      Method: kGet
2022-02-01 19:45:29.896 24385-24385/? V/chromium: [VERBOSE1:redeem_unblinded_token.cc(127)] OnFetchPaymentToken
2022-02-01 19:45:29.896 24385-24385/? V/chromium: [VERBOSE6:redeem_unblinded_token.cc(129)] URL Response:
      URL: *********************************************************************************************
      Response Status Code: 200
      Response: {"id":"043e683c-30d9-4ec9-bdcc-b5c6d0634d2e","createdAt":"2022-02-01T14:15:28.929Z","type":"view","modifiedAt":"2022-02-01T14:15:28.944Z","creativeInstanceId":"51354073-1525-4756-b97d-6a21f8946d65","paymentToken":{"publicKey":"et2CXJA+egWCrmON9MaT1gJnKuHKr/MKqXkCH1S6P3g=","batchProof":"1+p0IrvVzrluD6RWKxN/edTxclxVbxJm2B+XSBF0ywwZjYkXWwJ5nbRd0S5OuPw/vih4lJ5UX0PYCBJkcuzSDQ==","signedTokens":["4vmHySNrB0gtKXFwuW1xj9zdCKX/YeUV4Um+9N9Yw2o="]}}
2022-02-01 19:45:29.908 24385-24385/? V/chromium: [VERBOSE1:confirmations.cc(260)] Successfully redeemed unblinded token with confirmation id 043e683c-30d9-4ec9-bdcc-b5c6d0634d2e, creative instance id 51354073-1525-4756-b97d-6a21f8946d65 and view
2022-02-01 19:45:29.912 24385-24385/? V/chromium: [VERBOSE1:confirmations.cc(283)] Added 1 unblinded payment token with an estimated redemption value of 0.005 BAT, you now have 1 unblinded payment tokens
2022-02-01 19:45:29.915 24385-24385/? V/chromium: [VERBOSE1:refill_unblinded_tokens.cc(71)] No need to refill unblinded tokens as we already h

Case 4: View ads and then reset rewards and then upgrade profile to 1.35.x - Failed

  • Failed due to known issue with reset rewards #8776

@aman-m1
Copy link

aman-m1 commented Feb 2, 2022

The counter Current earnings this month (estimated) is showing only the Ads not-reconciled. It should also include Ads reconciled in this month (Feb). I tested this from database.sqlite file in Version 1.37.17 Chromium: 98.0.4758.87 (Official Build) nightly (64-bit). Please check.

@tmancey
Copy link
Collaborator Author

tmancey commented Feb 2, 2022

@aman-m1 I have checked and the values are correct for me. Please email me at terry@brave.com with your findings so I can check.

@aman-m1
Copy link

aman-m1 commented Feb 2, 2022

I have sent. Please check.

@LaurenWags LaurenWags removed the QA/In-Progress Indicates that QA is currently in progress for that particular issue label Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1_point For Agile sizing enhancement feature/ads OS/Android Fixes related to Android browser functionality OS/Desktop OS/iOS Fixes related to iOS browser functionality priority/P3 The next thing for us to work on. It'll ride the trains. QA Pass - Android ARM QA Pass - Android Tab QA Pass-Win64 QA/Yes release-notes/exclude
Projects
Ads
  
Done
Development

Successfully merging a pull request may close this issue.

6 participants