[ASDisplayNode] Failing Test Case: Rasterized Nodes Should Get Interface State Updates (#2242)

* Add new failing test cases for dealloc-while-visible

* Disable the new tests for the time being
This commit is contained in:
Adlai Holler
2016-09-27 19:54:52 -04:00
committed by GitHub
parent 2f99951732
commit 37d9d401b3

View File

@@ -1942,6 +1942,36 @@ static bool stringContainsPointer(NSString *description, id p) {
XCTAssertEqual(contentsAfterRedisplay, node.contents);
}
// Underlying issue for: https://github.com/facebook/AsyncDisplayKit/issues/2205
- (void)DISABLED_testThatNodesAreMarkedInvisibleWhenRemovedFromAVisibleRasterizedHierarchy
{
ASCellNode *supernode = [[ASCellNode alloc] init];
supernode.shouldRasterizeDescendants = YES;
ASDisplayNode *node = [[ASDisplayNode alloc] init];
UIWindow *window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
[supernode addSubnode:node];
[window addSubnode:supernode];
[window makeKeyAndVisible];
XCTAssertTrue(node.isVisible);
[node removeFromSupernode];
XCTAssertFalse(node.isVisible);
}
// Underlying issue for: https://github.com/facebook/AsyncDisplayKit/issues/2205
- (void)DISABLED_testThatNodesAreMarkedVisibleWhenAddedToARasterizedHierarchyAlreadyOnscreen
{
ASCellNode *supernode = [[ASCellNode alloc] init];
supernode.shouldRasterizeDescendants = YES;
ASDisplayNode *node = [[ASDisplayNode alloc] init];
UIWindow *window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
[window addSubnode:supernode];
[window makeKeyAndVisible];
[supernode addSubnode:node];
XCTAssertTrue(node.isVisible);
[node removeFromSupernode];
XCTAssertFalse(node.isVisible);
}
// Underlying issue for: https://github.com/facebook/AsyncDisplayKit/issues/2011
- (void)testThatLayerBackedSubnodesAreMarkedInvisibleBeforeDeallocWhenSupernodesViewIsRemovedFromHierarchyWhileBeingRetained
{