webrtc_m130/webrtc/sdk/objc/Framework/UnitTests/RTCMTLVideoViewTests.mm

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

188 lines
5.4 KiB
Plaintext
Raw Normal View History

Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
/*
* Copyright 2017 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
#import <Foundation/Foundation.h>
#import <OCMock/OCMock.h>
#include "webrtc/base/gunit.h"
#include <Metal/RTCMTLNV12Renderer.h>
#include <WebRTC/RTCMTLVideoView.h>
// Extension of RTCMTLVideoView for testing purposes.
@interface RTCMTLVideoView (Testing)
+ (BOOL)isMetalAvailable;
+ (UIView*)createMetalView:(CGRect)frame;
+ (id<RTCMTLRenderer>)createNV12Renderer;
+ (id<RTCMTLRenderer>)createI420Renderer;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
- (void)drawInMTKView:(id)view;
@end
@interface RTCMTLVideoViewTests : NSObject
@property(nonatomic, strong) id classMock;
@property(nonatomic, strong) id metalViewMock;
@property(nonatomic, strong) id rendererNV12Mock;
@property(nonatomic, strong) id rendererI420Mock;
@property(nonatomic, strong) id frameMock;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
@end
@implementation RTCMTLVideoViewTests
@synthesize classMock = _classMock;
@synthesize metalViewMock = _metalViewMock;
@synthesize rendererNV12Mock = _rendererNV12Mock;
@synthesize rendererI420Mock = _rendererI420Mock;
@synthesize frameMock = _frameMock;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
- (void)setup {
self.classMock = OCMClassMock([RTCMTLVideoView class]);
}
- (void)tearDown {
[self.classMock stopMocking];
[self.rendererI420Mock stopMocking];
[self.rendererNV12Mock stopMocking];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[self.metalViewMock stopMocking];
[self.frameMock stopMocking];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
self.classMock = nil;
self.rendererI420Mock = nil;
self.rendererNV12Mock = nil;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
self.metalViewMock = nil;
self.frameMock = nil;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
- (id)frameMockWithNativeHandle:(BOOL)hasNativeHandle {
id frameMock = OCMClassMock([RTCVideoFrame class]);
if (hasNativeHandle) {
OCMStub([frameMock nativeHandle]).andReturn((CVPixelBufferRef)[OCMArg anyPointer]);
} else {
OCMStub([frameMock nativeHandle]).andReturn((CVPixelBufferRef) nullptr);
}
return frameMock;
}
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
- (id)rendererMockWithSuccessfulSetup:(BOOL)sucess {
id rendererMock = OCMProtocolMock(@protocol(RTCMTLRenderer));
OCMStub([rendererMock addRenderingDestination:[OCMArg any]]).andReturn(sucess);
return rendererMock;
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
#pragma mark - Test cases
- (void)testInitAssertsIfMetalUnavailabe {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// given
OCMStub([self.classMock isMetalAvailable]).andReturn(NO);
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// when
BOOL asserts = NO;
@try {
RTCMTLVideoView *realView = [[RTCMTLVideoView alloc] initWithFrame:CGRectZero];
(void)realView;
} @catch (NSException *ex) {
asserts = YES;
}
EXPECT_TRUE(asserts);
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
- (void)testRTCVideoRenderNilFrameCallback {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// given
OCMStub([self.classMock isMetalAvailable]).andReturn(YES);
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoView *realView = [[RTCMTLVideoView alloc] init];
self.frameMock = OCMClassMock([RTCVideoFrame class]);
[[self.frameMock reject] nativeHandle];
[[self.classMock reject] createNV12Renderer];
[[self.classMock reject] createI420Renderer];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// when
[realView renderFrame:nil];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[realView drawInMTKView:self.metalViewMock];
// then
[self.frameMock verify];
[self.classMock verify];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
- (void)testRTCVideoRenderFrameCallbackI420 {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// given
OCMStub([self.classMock isMetalAvailable]).andReturn(YES);
self.rendererI420Mock = [self rendererMockWithSuccessfulSetup:YES];
self.frameMock = [self frameMockWithNativeHandle:NO];
OCMExpect([self.rendererI420Mock drawFrame:self.frameMock]);
OCMExpect([self.classMock createI420Renderer]).andReturn(self.rendererI420Mock);
[[self.classMock reject] createNV12Renderer];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoView *realView = [[RTCMTLVideoView alloc] init];
// when
[realView renderFrame:self.frameMock];
[realView drawInMTKView:self.metalViewMock];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// then
[self.rendererI420Mock verify];
[self.classMock verify];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
- (void)testRTCVideoRenderFrameCallbackNV12 {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
// given
OCMStub([self.classMock isMetalAvailable]).andReturn(YES);
self.rendererNV12Mock = [self rendererMockWithSuccessfulSetup:YES];
self.frameMock = [self frameMockWithNativeHandle:YES];
OCMExpect([self.rendererNV12Mock drawFrame:self.frameMock]);
OCMExpect([self.classMock createNV12Renderer]).andReturn(self.rendererNV12Mock);
[[self.classMock reject] createI420Renderer];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoView *realView = [[RTCMTLVideoView alloc] init];
// when
[realView renderFrame:self.frameMock];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[realView drawInMTKView:self.metalViewMock];
// then
[self.rendererNV12Mock verify];
[self.classMock verify];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
}
@end
TEST(RTCMTLVideoViewTests, InitAssertsIfMetalUnavailabe) {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoViewTests *test = [[RTCMTLVideoViewTests alloc] init];
[test setup];
[test testInitAssertsIfMetalUnavailabe];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[test tearDown];
}
TEST(RTCMTLVideoViewTests, RTCVideoRenderNilFrameCallback) {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoViewTests *test = [[RTCMTLVideoViewTests alloc] init];
[test setup];
[test testRTCVideoRenderNilFrameCallback];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[test tearDown];
}
TEST(RTCMTLVideoViewTests, RTCVideoRenderFrameCallbackI420) {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoViewTests *test = [[RTCMTLVideoViewTests alloc] init];
[test setup];
[test testRTCVideoRenderFrameCallbackI420];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[test tearDown];
}
TEST(RTCMTLVideoViewTests, RTCVideoRenderFrameCallbackNV12) {
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
RTCMTLVideoViewTests *test = [[RTCMTLVideoViewTests alloc] init];
[test setup];
[test testRTCVideoRenderFrameCallbackNV12];
Reland of Add unit tests for RTCMTLVideoView. (patchset #1 id:1 of https://codereview.webrtc.org/2733953006/ ) Reason for revert: Dependant CL has been relanded Original issue's description: > Revert of Add unit tests for RTCMTLVideoView. (patchset #6 id:100001 of https://codereview.webrtc.org/2723903003/ ) > > Reason for revert: > This CL depends on a reverted CL. > > Original issue's description: > > Add unit tests for RTCMTLVideoView. > > > > To properly test the functionality, following changes were needed > > - Make RTCMTLVideoView compiliable for all cpu architectures not just arm64. > > This is needed so that the test can run on any device and on simulator as well. > > - Refactor RTCMTLVideoView to have mockable class methods. > > The unittest class, RTCMTLVideoViewTests was designed to provide easy transition > > to XCTest when the time comes for that. > > To transition to XCTest it would suffice to inherit from XCTestCase and remove > > the gtest methods. > > > > BUG=webrtc:7079 > > > > Review-Url: https://codereview.webrtc.org/2723903003 > > Cr-Commit-Position: refs/heads/master@{#17014} > > Committed: https://chromium.googlesource.com/external/webrtc/+/0ebe0199acd1070f17ca2abc5bc22fdd8b0861ca > > TBR=magjed@webrtc.org,denicija@webrtc.org > # Not skipping CQ checks because original CL landed more than 1 days ago. > BUG=webrtc:7079 > > Review-Url: https://codereview.webrtc.org/2733953006 > Cr-Commit-Position: refs/heads/master@{#17118} > Committed: https://chromium.googlesource.com/external/webrtc/+/96d91524fa66b9a2e4f9fbbbc9c5e5149021a3f0 TBR=magjed@webrtc.org,denicija@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=webrtc:7079 Review-Url: https://codereview.webrtc.org/2743663002 Cr-Commit-Position: refs/heads/master@{#17140}
2017-03-09 03:36:58 -08:00
[test tearDown];
}