1
0
Fork 0
Commit Graph

443 Commits (d0e9f1f1654d60d2b056f488d6ac84dc39b268c5)

Author SHA1 Message Date
David Walsh 3feab90b19 For issue #9949 - Bookmarks/History deletion inconsistencies
- Added the undo action for deleting individual history items by creating a new field to the history state containing the id's of the history items that are pending for deletion; This field is used inside the update function from the view to show/hide the items.

 - Added a new check inside the "deleteMulti" method from BookmarkFragment that calls the showRemoveFoldersDialog to prevent the user from being able to delete one or more bookmark folders without being asked for confirmation, as in #8648.
2020-06-17 14:42:51 -04:00
Tiger Oakes f6efb386d6 Add tests for addon details 2020-06-17 14:38:50 -04:00
Tiger Oakes d3d5c8934f Cleanup tests for toolbar controller 2020-06-15 15:25:33 -04:00
Jonathan Almeida e6da2bd910 Fix breaking APIs in TabsAdapter and ViewHolder 2020-06-13 16:02:31 -04:00
David Walsh 8b24cdec42
For 11428 - Focus on home screen address bar when tab tray new tab is tapped (#11429) 2020-06-12 17:55:07 -05:00
Tiger Oakes 2fdebada11 Add tests for about viewholder 2020-06-12 15:30:50 -04:00
Tiger Oakes 294f29768d Test logins settings 2020-06-12 15:30:50 -04:00
Tiger Oakes 0d4ceb186c Add test for SearchStringValidator 2020-06-12 15:29:58 -04:00
Sawyer Blatz 0a9afbed42 For #11380: Update migration tip text 2020-06-12 15:17:53 -04:00
Sawyer Blatz 13d077eb66
For #11269: Telemetry for new reader mode position (#11385) 2020-06-12 11:39:35 -07:00
Tiger Oakes 651b2831fe Fix tests in toolbar controller 2020-06-11 18:15:09 -04:00
person808 d14b39a56e For #2165 - Implement pull-to-refresh gesture to sync history. 2020-06-11 10:23:27 -07:00
Tiger Oakes f0295048fa Remove Mockito 2020-06-10 21:19:50 -04:00
Jeff Boek cd3b6181b3 For #10374 - Adds quick contextual menu to tab switcher
Co-authored-by: person808 <kainaluh808@gmail.com>
2020-06-10 16:50:28 -07:00
Tiger Oakes 4b064afb81
Add tests for ext package (#11334) 2020-06-10 09:14:18 -07:00
ValentinTimisica 5200e00c4c For #5148: Adds tests for OpenSpecificTabIntentProcessor 2020-06-09 22:39:39 -04:00
Tiger Oakes 96d2307df0 Add tests for widget 2020-06-09 22:31:12 -04:00
Tiger Oakes 434a737abf Add tests for tips 2020-06-09 22:30:30 -04:00
Tiger Oakes c270a5c6f7 Fixes #8725 - Allow for async execution order 2020-06-09 22:22:47 -04:00
Christian Sadilek 05496faa66 Clear speculative session on engine settings change 2020-06-09 18:55:43 -04:00
ekager 6d4a673c6f For #8967 - Expose autofill logins setting in nightly 2020-06-09 12:21:48 -04:00
Sawyer Blatz e9189dc089 For #11045: Add reader mode to urlView 2020-06-08 15:12:03 -07:00
Tiger Oakes 1a19b06227
Simplify `PhoneFeature` code (#10810) 2020-06-08 13:02:42 -07:00
Jeff Boek 52c2fdb310
Remove tab tray feature flag (#11176)
* For #11171 - Removes feature flag for the new tab tray

* For #11171 - Removes all tab references from homeFragment

* For #11171 - Fixes unit tests

* For #11171 - Gets UI tests to compile and HomeScreenTest to pass

* For #11171 - Fixes `deleteMultipleSelectionTest`

* For #11171 - Fixes `openHistoryItemInNewPrivateTabTest`

* For #11171 - Fixes `openHistoryInPrivateTabTest`

* For #11171 - Fixes `openHistoryInNewTabTest`

* For #11171 - Fixes `openNewPrivateTabTest`

* For #11171 - Fixes tabbedBrowsingTests

* For #11171 - Fixes SettingsPrivacyTest

* For #11171 - Fixes TopSitesTest

* For #11171 - Fixes lint errors

* Ignore
2020-06-05 12:59:08 -05:00
Dennis Schubert d046d908fc Bug 1643132 - Remove native "Report site issue" functionality.
This will be replaced by the WebCompat team's system extension that ships as an android-component.
2020-06-04 18:23:11 -04:00
mcarare a910698007 For #11182: Set click listener also to icon button. 2020-06-04 11:50:29 -04:00
mcarare a7039b15e9 For #11182: Update unit tests to reflect click listener update. 2020-06-03 23:01:44 -04:00
person808 9272026b7e For #10193 - Remove page title when sharing links 2020-06-03 15:54:23 -07:00
Tiger Oakes a7e74e308b
Migrate some SessionManager usage to BrowserStore (#10789) 2020-06-03 11:18:44 -07:00
Tiger Oakes 2a0e2f2878 Fix failing CollectionCreationBottomBarViewTest 2020-06-02 12:07:53 -04:00
Tiger Oakes 6317eea690 Add tests for some of collection creation 2020-06-02 10:06:17 -04:00
Tiger Oakes 50441e28f1 Tests and cleanup for tracking protection 2020-06-01 22:08:52 -04:00
ekager 9ef4d9bdae For #10968 - Don't show ETP CFR if toolbar doesn't have window focus 2020-06-01 15:35:00 -07:00
Vishwa Patel 4da22c605a For #10834 - Adding Sync Tabs Feature in Fenix 2020-06-01 16:52:40 -04:00
Jeff Boek a6e77e3e8f For #10848 - Fixes unit tests 2020-05-30 10:38:48 -07:00
Jonathan Almeida 9f95cff6c4 Close #7749: Fix broken IntentReceiverActivity tests 2020-05-30 00:30:35 -04:00
Jonathan Almeida e995a98819 Revert "Disable failing intent handling unit tests"
This reverts commit c956f8b2afc988444771d86072adc94598c602c3.
2020-05-30 00:30:35 -04:00
Tiger Oakes 221792c074
Add tests for FenixOnboarding (#11057) 2020-05-29 17:26:07 -07:00
Gabriel Luong 63e529ac2b Added BrowserThumbnails dependencies 2020-05-29 18:19:06 -04:00
Jeff Boek 8662164b8a
Refactors the TabTrayDialogFragment to ditch that weird interactor (#11061)
* For #11056 - Removes unused argument when navigating to the collection creation fragment

* For #11056 - Moved the collection creation navigation logic to the TabTrayDialogFragment

* For #11056 - Moves navigating to the share screen from home/browser to the TabTrayDialogFragment

* For #11056 - We moved tab selection logic from home/browser to the tab tray dialog

* For #11056 - Moved new tab tapped logic to the tab tray dialog fragment

* For #11056 - Removes all interactor logic for the TabTrayDialogFragment

* For #11056 - Migrates the presentation / navigation around the TabTrayDialog to the androidx navigation library
2020-05-29 17:17:56 -05:00
ekager 20e358228e For #11015 - Switch Default ETP Setting to Standard 2020-05-29 16:39:47 -04:00
Tiger Oakes 749c95e0f0
Add tests for ReaderModeController (#11049) 2020-05-29 11:46:31 -07:00
David Walsh 4fdac4d608
For 10734 - Open tab tray when collection is opened from Home (#10751)
* For 10734 - Open tab tray when collection is opened from Home

* Update to work with tab tray drawer
2020-05-28 10:22:12 -05:00
Tiger Oakes 2397695fe5
For #10596 - Redirect moz://a URL (#10688) 2020-05-26 11:06:01 -07:00
Sawyer Blatz 7067e5c000
For #8125: Add default top site telemetry (#10752) 2020-05-22 13:10:09 -07:00
Jeff Boek 601aedda46 For #10504 - Removes "old" TabTrayFragment 2020-05-21 15:17:20 -07:00
Christian Sadilek 4e25f41a41 For #1824: Prevent extremely long URLs from locking up HomeFragment 2020-05-21 13:11:07 -04:00
codrut.topliceanu 7feae98944 For #9044 - Replace DownloadNotificationBottomSheetDialog with unobtrusive view
- Renamed DownloadNotification and removed DownloadState.dismissed dependency
- Improved DynamicDownloadDialog behaviour when scrolling
- DynamicDownloadDialog remains attached to tab until dismissed
- Fixed onTryAgain not working for resumed DownloadDialogs
2020-05-21 10:02:51 -04:00
Elise Richards edc75c3ad0
Fixes #9504: Edit logins (#9693)
* Create editable view and fragment. Update login info page to display options menu with edit and delete.

* Create feature flag for edit. Check flag in the login detail fragment and default to just delete.

* Add three-dot kebab options menu in login detail fragment. Add title to the login item.

* Nav to and from edit view on save and back pressed.

* Save login through AC login manager. Clear text in editable field on button click.

* Match colors, fonts, dimens to UX specs for edit logins. Enable password reveal/hide and clearing text fields.

* Refactoring logins fragments. Using component Login object for consistency.

Fetch login list when saved logins are opened. Fetch login details when detail view is opened.

Revert "Fetch login list when saved logins are opened. Fetch login details when detail view is opened."

This reverts commit 44fe17166c3332b330229258b2e8982832672e3b.

* Using parcelable login and Login component class to pass ids and items between fragments

* Retrieve login from storage when viewing login details.

Rename login logic for consistency.

Ktlint cleanup

Fix nits and naming consistency.

* UX consistency for login detail and edit login pages

* Rebasing with logins sort - updating logins store.

* Rebasing with logins sort - merging fragments and controllers.

* Lint and removing unused files.

* UX cleanup.

* Update string description
2020-05-12 17:32:01 -05:00
Sebastian Kaspari d58c022619 Integrate activity for showing past crashes. 2020-05-12 09:14:20 +02:00
ValentinTimisica 1e83f54a94 For #10343: Updates UI tests accordingly to 'Library' removal 2020-05-11 10:22:19 -07:00
codrut.topliceanu d1005dd236 For #8589 - Fix for accessibility navigation in ETP panel 2020-05-08 09:57:59 -07:00
Sawyer Blatz 02f6e6868e
For #10426: Adds identifier to Glean for 24 hours (#10446) 2020-05-07 08:57:20 -07:00
ValentinTimisica 77705d1a27 For #9505: Adds tests for sort saved logins 2020-05-07 08:43:59 -07:00
Christian Sadilek fee09c3092 No issue: Show article/page url instead of reader extension url 2020-05-05 17:52:27 -04:00
Jeff Boek d72e455c0d No Issue - Update to AC 41.0.20200505190119 2020-05-05 17:52:27 -04:00
Mihai Eduard Badea 02bd0cc203 For issue #8648 2020-04-29 09:48:42 -07:00
Arturo Mejia a8843def6c Fix CrashReporterService breaking changes 2020-04-27 16:43:05 -04:00
Mihai Branescu a16bfb27ef For #6557 - added unit tests 2020-04-24 15:47:48 -07:00
Mihai Branescu c4d76dce5a For #6558 - cleanup + added unit tests 2020-04-24 09:28:40 -07:00
ekager c4e83367f6 For #6832 - Fix various fragment not attached to a context crashes 2020-04-22 20:56:35 -07:00
ekager 5d51c4f059 Don't use ProcessLifecycleOwner for view-tied consume 2020-04-20 12:07:37 -07:00
Grisha Kruglov 853a0acab4 Closes #4046: Always display 'Desktop' bookmarks folder
See https://github.com/mozilla-mobile/fenix/issues/4046 for a detailed discussion of this.

In short, this patch removes code that would conditionally hide desktop bookmarks depending
on the signed-in state of the browser.
2020-04-17 23:57:43 -07:00
Michael Comella f49fc6dad2 For #8803: hook up frameworkStart metric. 2020-04-17 09:11:58 -07:00
Michael Comella dbf733d70a For #8803: add StartupFrameworkStartMeasurement.
This class controls the central logic around the metrics we want to
record.
2020-04-17 09:11:58 -07:00
Michael Comella 7f618a6a7c For #8803: add Stat and test.
We need to access the data in stat to get the process start time, so we
can calculate the time from process start until application.init for the
frameworkStart probe.
2020-04-17 09:11:58 -07:00
mcarare e87ea301ab For #9536: Update tests to check opened tab is in same browsing mode 2020-04-16 19:50:25 -07:00
Jeff Boek 4cbb9aebaf
Cleans up nav_graph.xml (#9829)
* For #9751 - Cleans up homeFragment directions

* For #9751 - Uses global actions for fragments not owned by homeFragment

* For #9751 - Cleans up SearchFragment directions

* For #9751 - Removes settings action from DeleteBrowsingDataFragment

* For #9751 - Removes browser action from SettingsFragment

* For #9751 - Adds ManagePhoneFeature global action

* For #9751 - Clean up unused deletebrowsingfragment actions

* For #9751 - Cleans Up HistoryFragment actions

* For #9751 - Removes Home -> Search action

* For #9751 - Removes the Bookmark -> Browser action

* For #9751 - Cleans up bookmark fragment actions

* For #9751 - Cleans up actions from ShareController

* For #9751 - Removes defaultBrowserFragment to browserFragment action

* For #9751 - Removes about -> browser action

* For #9751 - Adds global action to TrackingProtectionFragment

* For #9751 - Removes exception -> browser action

* For #9751 - Removes login -> browser action

* For #9751 - Fixes LoginFragment directions

* For #9751 - Removes ExternalAppBrowser directions

* for #9751 - Cleans up actions

* For #9751 - Fixes unit tests

* For #9751 - Addresses nits in PR
2020-04-13 21:43:45 -07:00
ekager 8c238402e2 For #9692 - Fix "Install" PWA menu item labeling 2020-04-13 10:09:37 -07:00
mcarare 8cdc523de9 For #9698: Add unit tests for Context extension getStringWithArgSafe 2020-04-13 09:40:00 +03:00
Christian Sadilek 0f1bff7402 No issue: Refactor readerview to use browser-state 2020-04-07 16:31:03 -04:00
Mihai Eduard Badea d66da53c9a For #2768 - Prevent screenshots in private mode
Added a new option in Private browsing menu to allow or prevent screenshots from being taken while in private mode by adding or removing the FLAG_SECURE flag from the home activity's window.

 This method is called whenever the activity is initialized to account for the browsing mode being changed and whenever the setting from the Private browsing menu is changed.

 The setting is by default set to true (screenshots are allowed to be taken)
2020-04-07 17:23:06 +03:00
Michael Comella 376740cd2c For #9631: replace assertk assertions with junit.
I created a series of editor macros to do this with minimal errors (and
to do it quickly!).
2020-04-06 16:56:40 -07:00
Mihai Adrian dfded8e69c
For #9687: Refactor onboarding cards to follow app architecture (#9743)
* For #9687: Refactor onboarding cards to follow app architecture

* For #9687: Update unit test to new controller parameters
2020-04-06 11:00:47 -07:00
Michael Comella 51a76651d6 For #9605 - review: clarify comments in new test runner. 2020-04-03 09:27:49 -07:00
Michael Comella efef8eaba0 For #9605: TestApplication -> FenixRobolectricTestApplication.
This disambiguates it from the FirefoxTestApplication used in on-device
tests.
2020-04-03 09:27:49 -07:00
Michael Comella 8df49473c0 For #9605: move TestApplication to the helpers package.
The helpers/ package is created to separate the test support code from
the code under test.
2020-04-03 09:27:49 -07:00
Michael Comella 6e0d851da3 For #9605: replace unit test runners with FenixRobolectricTestRunner.
This is how we can apply the new test runner to remove duplication.

This commit was generated programmatically with the following commands:
```
  // Replace test runners with new one.
  find app/src/test -type f -exec gsed -i "s/@RunWith(RobolectricTestRunner::class)/@RunWith(FenixRobolectricTestRunner::class)/" {} +
  find app/src/test -type f -exec gsed -i "s/@RunWith(AndroidJUnit4::class)/@RunWith(FenixRobolectricTestRunner::class)/" {} +

  // Replace imports of old test runners with new one
  find app/src/test -type f -exec gsed -i "s/org.robolectric.RobolectricTestRunner/org.mozilla.fenix.helpers.FenixRobolectricTestRunner/" {} +
  find app/src/test -type f -exec gsed -i "s/androidx.test.ext.junit.runners.AndroidJUnit4/org.mozilla.fenix.helpers.FenixRobolectricTestRunner/" {} +

  // Remove unused imports
  find app/src/test -type f -exec gsed -i "/@Config(application = TestApplication::class)/d" {} +
  find app/src/test -type f -exec gsed -i "/import org.mozilla.fenix.TestApplication/d" {} +
  find app/src/test -type f -exec gsed -i "/import org.robolectric.annotation.Config/d" {} +
```

Where gsed is the GNU version of sed installed via homebrew. After
running these commands, I need to manually clean up the following files:
- FenixRobolectricTestRunner
- LocaleManagerExtensionTest
2020-04-03 09:27:49 -07:00
Michael Comella b0cfa3ee5c For #9605: add FenixRobolectricTestRunner.
This class will help us reduce duplication by specifying the
configuration within the test runner rather than each test needing to
specify it itself.

This class is adapted from Firefox for Fire TV:
  https://github.com/mozilla-mobile/firefox-tv/blob/master/app/src/test/java/org/mozilla/tv/firefox/helpers/FirefoxRobolectricTestRunner.kt
2020-04-03 09:27:49 -07:00
Michael Comella 392dda5eda For #9605: remove unnecessary @RunWith(Robolectric in unit tests.
robolectric increases the run time of tests so it's important to remove
them when they're unnecessary.

Between this change and the last one, the unit test runtime was reduced
by ~10s.
2020-04-03 09:27:49 -07:00
Michael Comella f2acef66b5 For #9605: remove unnecessary @RunWith(AndroidJUnit4) in unit tests.
In unit tests, this annotation annotations defer to robolectric, non-trivially
increasing test runtime so it's important to remove them when they're
unnecessary.
2020-04-03 09:27:49 -07:00
Mihai Adrian 8cd6d7460c
For #9336 Check current destination before navigating (#9353)
* For #9336 Check current destination before navigating

* For #9336 Update unit test to check for navigateSafe
2020-04-01 15:36:56 -07:00
mcarare 76f15a1f7f For #9498: Update unit tests with new constructor argument 2020-03-30 09:56:51 -07:00
Sebastian Kaspari 02aabea14a Update to new feature-media API. 2020-03-29 23:13:13 -07:00
Amaan Marfatia 3dcfed3761 AboutPageAdapter doesn't use notifyDataSetChanged()
We make the AboutPageAdapter inherit from a ListAdapter so that we don't use notifyDataSetChanged().
2020-03-27 17:23:27 -07:00
Mugurell 9f3bbf1fb7 For #8651 - Add HistoryInteractor/Controller unit/ui tests 2020-03-27 15:53:31 -07:00
mcarare 55ea92be5b For #8759 Update Unit tests with activityName instead of packageName 2020-03-24 17:10:19 +02:00
Severin Rudie 35a132d7ff
8017 advanced autoplay controls. (#8978)
* For #8017: add advanced autoplay controls
2020-03-20 12:10:42 -07:00
Arturo Mejia 7dff584b82 Remove @ObsoleteCoroutinesApi from tests 2020-03-18 17:25:51 -07:00
Jonathan Almeida ffd4cdd970 For #7661: Add variant-specific schemas for deep links
In order to target specific variants of Fenix, we're adding schemas that
are specific that app in order to avoid collisions with the other
variants and with other forks of fenix that may have the same schemas.

The current schema for variants:
 - Fenix Nightly: `fenix-nightly://`
 - Fenix Beta: `fenix-beta://`
 - Everything else: `fenix://`
2020-03-17 17:21:09 -04:00
Severin Rudie 3e38b002dd
No issue: fixes test broken by snapshot (#9176)
* No issue: fixes test broken by snapshot

* No issue: ignore flaky tests
2020-03-16 16:44:39 -07:00
Michael Comella 5bd0369aed No issue: remove unused HotStartPerformanceMonitor.
This monitor for hot start was intended to be used by FNPRMS to measure
hot start. However, hot start was deprioritized so it's now essentially
unused.
2020-03-11 11:28:38 -07:00
Mihai Branescu b0e4453fb7 For #8800 - add tests for dismissing highlighted items 2020-03-11 19:05:55 +02:00
mcarare 95a89f9dba For #8474 Remove obsolete unit tests for removed menu items 2020-03-11 09:52:28 -07:00
Arturo Mejia ce4293c8c8 For issue #8908 Notify users when previously unsupported add-ons
become available
2020-03-11 11:24:01 -04:00
Severin Rudie e86120027f For #9091: fix test failure 2020-03-11 14:51:05 +01:00
mcarare 7ae1304612 For #8975: Update unit tests for new separator between title and url 2020-03-05 21:17:36 -08:00
Sawyer Blatz 3548e58c00
For #7158: Improves browser to search animation (#8961) 2020-03-05 12:29:23 -08:00
Sebastian 7b170c4428 Update IntentProcessor implementation to comply with new interface. 2020-03-04 09:40:00 -08:00
ekager e2bfe8d0db For #8621 - Disable failing handlePermissionsChange test 2020-03-04 08:13:46 -08:00