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

do not allow showing resources blocked if there's none #42

Merged
merged 1 commit into from
Jul 3, 2018

Conversation

cezaraugusto
Copy link
Contributor

@cezaraugusto cezaraugusto commented Jul 2, 2018

fix brave/brave-browser#419
fix brave/brave-browser#429

Test Plan #1: (as described in brave/brave-browser#419)

  1. Visit wikipedia.org in a new tab
  2. Ensure shields shows badge as 0
  3. Open shields, you can click on all shields stats even though it shows 0 but it should not show any resource blocked as there's none.

Test Plan #2: (as described in brave/brave-browser#429)

  1. Visit icloud.com in a new tab and change to Block all fingerprinting
  2. See blocked count in shields
  3. Visit nytimes.com in the same tab
  4. Ensure there are no fingerprint blocked items
  5. Click on 0 Fingerprint blocked,. should not show any resource blocked as there's none

@cezaraugusto cezaraugusto self-assigned this Jul 2, 2018
@cezaraugusto cezaraugusto requested a review from yrliou July 2, 2018 21:32
Copy link
Member

@yrliou yrliou left a comment

Choose a reason for hiding this comment

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

I think we should reset resource arrays similar as what we did here, https://github.com/brave/brave-extension/blob/master/app/background/reducers/shieldsPanelReducer.ts#L67-L74, wdyt?
And probably have some unit tests added in

describe('ON_BEFORE_NAVIGATION', function () {
.

@bbondy
Copy link
Member

bbondy commented Jul 3, 2018

re: #42 (review) I think it can be done in a follow up if needed, so merging this.

@bbondy bbondy merged commit 1be1f9c into master Jul 3, 2018
@cezaraugusto cezaraugusto deleted the shields/419 branch July 3, 2018 19:29
cezaraugusto added a commit that referenced this pull request Jul 4, 2018
cezaraugusto added a commit that referenced this pull request Jul 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants