From c69e18bc6e0ac407d93b3f7e89359ea84bcd4977 Mon Sep 17 00:00:00 2001 From: Luke Parham Date: Sat, 19 Dec 2015 00:14:17 -0600 Subject: [PATCH] refactored test --- AsyncDisplayKitTests/ASVideoNodeTests.m | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/AsyncDisplayKitTests/ASVideoNodeTests.m b/AsyncDisplayKitTests/ASVideoNodeTests.m index 662f07224b..8dbb7e2e5e 100644 --- a/AsyncDisplayKitTests/ASVideoNodeTests.m +++ b/AsyncDisplayKitTests/ASVideoNodeTests.m @@ -36,11 +36,12 @@ - (void)testVideoNodeDoesNotReplaceAVPlayerItemWhenSameURLIsSet { ASVideoNode *videoNode = [[ASVideoNode alloc] init]; videoNode.interfaceState = ASInterfaceStateFetchData; + AVAsset *asset = [AVAsset assetWithURL:[NSURL URLWithString:@"firstURL"]]; - videoNode.asset = [AVAsset assetWithURL:[NSURL URLWithString:@"firstURL"]]; + videoNode.asset = asset; AVPlayerItem *item = [videoNode currentItem]; - videoNode.asset = [AVAsset assetWithURL:[NSURL URLWithString:@"firstURL"]]; + videoNode.asset = asset; AVPlayerItem *secondItem = [videoNode currentItem]; XCTAssertEqualObjects(item, secondItem);