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

Push domain exclusions to internal release #3076

Merged
merged 4 commits into from
Aug 7, 2024

Conversation

diegoreymendez
Copy link
Contributor

@diegoreymendez diegoreymendez commented Aug 6, 2024

Task/Issue URL: https://app.asana.com/0/0/1207987809385256/f

BSK PR: duckduckgo/BrowserServicesKit#928
iOS PR: duckduckgo/iOS#3195

Description

Implements domain exclusions for internal users only.

Testing

The tests were ordered in a way to try and make it easy to run them sequentially.

Make sure external users can't access domain exclusions

  1. If you're logged in as an internal user go to Debug Menu > Remove Internal User State.
  2. Open duckduckgo.com (or any other site)
  3. Open the in-app VPN status view and ensure there's no domain exclusions section.
  4. Connect the VPN.
  5. Repeat the check in step 3.

Make sure internal users can access domain exclusions through the in-app status view

  1. Login as an internal user at https://use-login.duckduckgo.com.
  2. Open duckduckgo.com and search for "What is my ip". Ensure you see your public IP.
  3. Make sure the VPN is stopped.
  4. Open the in-app VPN status view and ensure there's no domain exclusions section.
  5. Connect the VPN.
  6. Refresh the page and ensure you see the VPN IP address.
  7. Open the in-app VPN status view and ensure you see the domain exclusions section.
  8. Exclude the site, the VPN will briefly reconnect.
  9. Refresh the page and ensure you see the public IP address again.
  10. Repeat the process and check the IP is always properly reflected.

Make sure internal users can access domain exclusions through settings

  1. You can do similar steps in the previous tests, but checking also that Settings > VPN > Domain Exclusions properly shows and hides the domain exclusion section based on whether you're an internal user or not.
  2. Also check that adding a domain or removing a domain properly updates the exclusion (check for your IP in the site).

Definition of Done:


Internal references:

Pull Request Review Checklist
Software Engineering Expectations
Technical Design Template
Pull Request Documentation

diegoreymendez and others added 2 commits August 6, 2024 13:22
Comment on lines +148 to +153
<Test
Identifier = "TabContentTests/testWhenPDFContextMenuPrintChosen_printDialogOpens()">
</Test>
<Test
Identifier = "TabContentTests/testWhenPDFMainMenuPrintChosen_printDialogOpens()">
</Test>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Flaky tests, there are tasks for these.

@diegoreymendez
Copy link
Contributor Author

For clarity, just finished a self review and all looks good to me.

@diegoreymendez diegoreymendez changed the base branch from main to release/1.101.0 August 6, 2024 11:41
Copy link
Contributor

github-actions bot commented Aug 6, 2024

Warnings
⚠️ PR has more than 500 lines of code changing. Consider splitting into smaller PRs if possible.

Generated by 🚫 dangerJS against 7b7bee9

@diegoreymendez
Copy link
Contributor Author

This was already reviewed in #3045, so I'll go the route we usually take and consider this a glorified cherry-pick with CI validation.

I've also tested this extensively, I'll do one more round of testing and merge if all looks good to me.

diegoreymendez added a commit to duckduckgo/iOS that referenced this pull request Aug 7, 2024
Task/Issue URL: https://app.asana.com/0/0/1207987809385256/f

BSK PR: duckduckgo/BrowserServicesKit#928
macOS PR: duckduckgo/macos-browser#3076

## Description

Integrates latest macOS BSK changes for supporting domain exclusions.
@diegoreymendez
Copy link
Contributor Author

A flakey test is failing on UI tests, but it's not related to my changes. @SabrinaTardio mentioned she can fix it in a follow-up PR.

@diegoreymendez diegoreymendez merged commit 47731ad into release/1.101.0 Aug 7, 2024
21 of 24 checks passed
@diegoreymendez diegoreymendez deleted the diego/exclude-domains-internal branch August 7, 2024 14:00
graeme added a commit that referenced this pull request Oct 8, 2024
Task/Issue URL:
https://app.asana.com/0/1201048563534612/1208463834186044/f

**Description**:

For some weeks we've had reports about music playing after a browser
window playing music is closed. Turns out an indirect reference to the
WebView was being held through the `ActiveDomainPublisher` introduced
during #3076. I've made
an attempt at fixing this, but lemme know if there's a better way.

**Steps to test this PR**:
1. Open a single browser window.
2. Go to soundcloud.com and start any music playing
3. Close the window
**4. Music should stop playing**

**Definition of Done**:

* [ ] Does this PR satisfy our [Definition of
Done](https://app.asana.com/0/1202500774821704/1207634633537039/f)?

---
###### Internal references:
[Pull Request Review
Checklist](https://app.asana.com/0/1202500774821704/1203764234894239/f)
[Software Engineering
Expectations](https://app.asana.com/0/59792373528535/199064865822552)
[Technical Design
Template](https://app.asana.com/0/59792373528535/184709971311943)
[Pull Request
Documentation](https://app.asana.com/0/1202500774821704/1204012835277482/f)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant