PeerConnectionTest(objc): expect ICE Completed state post 61460797-p10

Also a few trivial cleanups:
- No need to use STUN for a loopback test
- Reduce test call duration 10s->2s for faster iteration
- Remove obviously-irrelevant Info.plist entries (copy/pasta from iOS)

BUG=1414,2993
R=noahric@google.com

Review URL: https://webrtc-codereview.appspot.com/9369004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@5663 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
fischman@webrtc.org
2014-03-07 22:15:30 +00:00
parent 781146964e
commit 13320ea3d3
2 changed files with 8 additions and 28 deletions

View File

@ -18,21 +18,7 @@
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>

View File

@ -97,28 +97,21 @@
- (void)testCompleteSession {
RTCPeerConnectionFactory *factory = [[RTCPeerConnectionFactory alloc] init];
NSString *stunURL = @"stun:stun.l.google.com:19302";
RTCICEServer *stunServer =
[[RTCICEServer alloc] initWithURI:[NSURL URLWithString:stunURL]
username:@""
password:@""];
NSArray *iceServers = @[stunServer];
RTCMediaConstraints *constraints = [[RTCMediaConstraints alloc] init];
RTCPeerConnectionSyncObserver *offeringExpectations =
[[RTCPeerConnectionSyncObserver alloc] init];
RTCPeerConnection *pcOffer =
[factory peerConnectionWithICEServers:iceServers
RTCPeerConnection* pcOffer =
[factory peerConnectionWithICEServers:nil
constraints:constraints
delegate:offeringExpectations];
RTCPeerConnectionSyncObserver *answeringExpectations =
[[RTCPeerConnectionSyncObserver alloc] init];
RTCPeerConnection *pcAnswer =
[factory peerConnectionWithICEServers:iceServers
RTCPeerConnection* pcAnswer =
[factory peerConnectionWithICEServers:nil
constraints:constraints
delegate:answeringExpectations];
// TODO(hughv): Create video capturer
RTCVideoCapturer *capturer = nil;
RTCVideoSource *videoSource =
@ -188,6 +181,7 @@
[offeringExpectations expectICEConnectionChange:RTCICEConnectionChecking];
[offeringExpectations expectICEConnectionChange:RTCICEConnectionConnected];
[offeringExpectations expectICEConnectionChange:RTCICEConnectionCompleted];
[answeringExpectations expectICEConnectionChange:RTCICEConnectionChecking];
[answeringExpectations expectICEConnectionChange:RTCICEConnectionConnected];
@ -219,11 +213,11 @@
[offeringExpectations waitForAllExpectationsToBeSatisfied];
[answeringExpectations waitForAllExpectationsToBeSatisfied];
// Let the audio feedback run for 10s to allow human testing and to ensure
// Let the audio feedback run for 2s to allow human testing and to ensure
// things stabilize. TODO(fischman): replace seconds with # of video frames,
// when we have video flowing.
[[NSRunLoop currentRunLoop]
runUntilDate:[NSDate dateWithTimeIntervalSinceNow:10]];
runUntilDate:[NSDate dateWithTimeIntervalSinceNow:2]];
// TODO(hughv): Implement orderly shutdown.
}