Skip to content

Commit

Permalink
More test updates
Browse files Browse the repository at this point in the history
  • Loading branch information
rahul-malik committed Jul 17, 2019
1 parent 36298da commit e56ebc0
Showing 1 changed file with 2 additions and 15 deletions.
17 changes: 2 additions & 15 deletions Tests/ASDisplayNodeTests.mm
Original file line number Diff line number Diff line change
Expand Up @@ -1918,30 +1918,17 @@ - (void)checkBackgroundColorOpaqueRelationshipWithViewLoaded:(BOOL)loaded layerB

if (loaded) {
// Force load
if (isLayerBacked) {
[node layer];
} else {
[node view];
}
[node layer];
}

XCTAssertTrue(node.opaque, @"Node should start opaque");
XCTAssertTrue(node.layer.opaque, @"Node should start opaque");

node.backgroundColor = [UIColor clearColor];
node.backgroundColor = [UIColor blackColor];

// This could be debated, but at the moment we differ from UIView's behavior to change the other property in response
XCTAssertTrue(node.opaque, @"Set background color should not have made this not opaque");
XCTAssertTrue(node.layer.opaque, @"Set background color should not have made this not opaque");

if (isLayerBacked) {
[node layer];
} else {
[node view];
}

XCTAssertTrue(node.opaque, @"Set background color should not have made this not opaque");
XCTAssertTrue(node.layer.opaque, @"Set background color should not have made this not opaque");
}

- (void)testBackgroundColorOpaqueRelationshipView
Expand Down

0 comments on commit e56ebc0

Please sign in to comment.