diff --git a/Source/Common/IGListExperiments.h b/Source/Common/IGListExperiments.h index cb42c666..dc625100 100644 --- a/Source/Common/IGListExperiments.h +++ b/Source/Common/IGListExperiments.h @@ -20,8 +20,6 @@ typedef NS_OPTIONS (NSInteger, IGListExperiment) { IGListExperimentBackgroundDiffing = 1 << 2, /// Test fallback to reloadData when "too many" update operations. IGListExperimentReloadDataFallback = 1 << 3, - /// Test deduping item-level updates. - IGListExperimentDedupeItemUpdates = 1 << 5, /// Test deferring object creation until just before diffing. IGListExperimentDeferredToObjectCreation = 1 << 6, /// Test getting collection view at update time. diff --git a/Source/IGListAdapterUpdater.m b/Source/IGListAdapterUpdater.m index 90e8be4e..eac64593 100644 --- a/Source/IGListAdapterUpdater.m +++ b/Source/IGListAdapterUpdater.m @@ -334,11 +334,6 @@ void convertReloadToDeleteInsert(NSMutableIndexSet *reloads, [itemDeletes addObjectsFromArray:[reloadDeletePaths allObjects]]; [itemInserts addObjectsFromArray:[reloadInsertPaths allObjects]]; - if (IGListExperimentEnabled(self.experiments, IGListExperimentDedupeItemUpdates)) { - itemDeletes = [[[NSSet setWithArray:itemDeletes] allObjects] mutableCopy]; - itemInserts = [[[NSSet setWithArray:itemInserts] allObjects] mutableCopy]; - } - IGListBatchUpdateData *updateData = [[IGListBatchUpdateData alloc] initWithInsertSections:inserts deleteSections:deletes moveSections:moves diff --git a/Tests/IGListAdapterE2ETests.m b/Tests/IGListAdapterE2ETests.m index d16fadce..7c91d173 100644 --- a/Tests/IGListAdapterE2ETests.m +++ b/Tests/IGListAdapterE2ETests.m @@ -1785,25 +1785,6 @@ [self waitForExpectationsWithTimeout:30 handler:nil]; } -- (void)test_whenInsertingItemTwice_withDedupeExperiment_thatSecondInsertGetsDropped { - ((IGListAdapterUpdater*)self.updater).experiments = IGListExperimentDedupeItemUpdates; - - IGTestObject *object = genTestObject(@1, @1); - [self setupWithObjects:@[object]]; - - IGTestDelegateController *controller = [self.adapter sectionControllerForObject:self.dataSource.objects.firstObject]; - XCTestExpectation *expectation = genExpectation; - [controller.collectionContext performBatchAnimated:YES updates:^(id _Nonnull batchContext) { - object.value = @2; - [batchContext insertInSectionController:controller atIndexes:[NSIndexSet indexSetWithIndex:0]]; - [batchContext insertInSectionController:controller atIndexes:[NSIndexSet indexSetWithIndex:0]]; - } completion:^(BOOL finished) { - [expectation fulfill]; - }]; - - [self waitForExpectationsWithTimeout:30 handler:nil]; -} - - (void)test_whenModifyingInitialAndFinalAttribute_thatLayoutIsCorrect { // set up the custom layout IGListCollectionViewLayout *layout = [[IGListCollectionViewLayout alloc] initWithStickyHeaders:NO topContentInset:0 stretchToEdge:YES];