Closed
Bug 1356375
Opened 7 years ago
Closed 7 years ago
Topsite cell count is not updated after deleting only Topsite icon left
Categories
(Firefox for iOS :: Home screen, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: njpark, Unassigned)
Details
Tests in TopsitesTest.swift is disabled, because test was crashing with view inconsistency. What happens is that when all of the topsite cells are that the count of visible cells decrease as the cells are deleted, but when the last cell is deleted, the count remains 1, yet the cell's isVisibleInViewHierachy() value is set to false. Hence, below code will hit break at the last iteration: var topSiteCell = tester().waitForView(withAccessibilityIdentifier: "TopSitesCell") as! ASHorizontalScrollCell var collection = topSiteCell.collectionView while collection.visibleCells.count > 0 { let firstCell = collection.visibleCells.first! if firstCell.isVisibleInViewHierarchy() == false { break } else { // Deletes the cell by long press -> select 'Remove' menu deleteSuggestedTopsite(firstCell.accessibilityLabel!) } } The workaround is that when the view is changed to something else, like Bookmarks, and return to Topsites view, the number will be updated. But since it had no problem decrementing the visible cell's count except in the case when there was only one cell left, I believe this is a bug that should be fixed. Farhan, is this something that can be fixed in short term? if not, then I'll mark the tests and put workaround to it.
Reporter | ||
Updated•7 years ago
|
Flags: needinfo?(fpatel)
Reporter | ||
Updated•7 years ago
|
Summary: Topsite cell count is not updated after deleting only Topsite icon → Topsite cell count is not updated after deleting only Topsite icon left
Comment 1•7 years ago
|
||
There's been some changes to Topsites so these tests will need to be completely rewritten.
Flags: needinfo?(fpatel)
Reporter | ||
Comment 3•7 years ago
|
||
wait, yeah this change is already made a while ago. closing it.
Status: NEW → RESOLVED
Closed: 7 years ago
Flags: needinfo?(npark)
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•