| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2015 The WebRTC Project Authors. All rights reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| 11 #include <map> | 11 #include <map> |
| 12 #include <memory> | 12 #include <memory> |
| 13 | 13 |
| 14 #include "webrtc/base/fakesslidentity.h" | 14 #include "webrtc/base/fakesslidentity.h" |
| 15 #include "webrtc/base/gunit.h" | 15 #include "webrtc/base/gunit.h" |
| 16 #include "webrtc/base/helpers.h" | 16 #include "webrtc/base/helpers.h" |
| 17 #include "webrtc/base/sslidentity.h" | 17 #include "webrtc/base/sslidentity.h" |
| 18 #include "webrtc/base/thread.h" | 18 #include "webrtc/base/thread.h" |
| 19 #include "webrtc/p2p/base/dtlstransportchannel.h" | 19 #include "webrtc/p2p/base/dtlstransportchannel.h" |
| 20 #include "webrtc/p2p/base/fakeportallocator.h" | |
| 21 #include "webrtc/p2p/base/faketransportcontroller.h" | 20 #include "webrtc/p2p/base/faketransportcontroller.h" |
| 22 #include "webrtc/p2p/base/p2ptransportchannel.h" | 21 #include "webrtc/p2p/base/p2ptransportchannel.h" |
| 23 #include "webrtc/p2p/base/portallocator.h" | 22 #include "webrtc/p2p/base/portallocator.h" |
| 24 #include "webrtc/p2p/base/transportcontroller.h" | 23 #include "webrtc/p2p/base/transportcontroller.h" |
| 24 #include "webrtc/p2p/client/fakeportallocator.h" |
| 25 | 25 |
| 26 static const int kTimeout = 100; | 26 static const int kTimeout = 100; |
| 27 static const char kIceUfrag1[] = "TESTICEUFRAG0001"; | 27 static const char kIceUfrag1[] = "TESTICEUFRAG0001"; |
| 28 static const char kIcePwd1[] = "TESTICEPWD00000000000001"; | 28 static const char kIcePwd1[] = "TESTICEPWD00000000000001"; |
| 29 static const char kIceUfrag2[] = "TESTICEUFRAG0002"; | 29 static const char kIceUfrag2[] = "TESTICEUFRAG0002"; |
| 30 static const char kIcePwd2[] = "TESTICEPWD00000000000002"; | 30 static const char kIcePwd2[] = "TESTICEPWD00000000000002"; |
| 31 | 31 |
| 32 using cricket::Candidate; | 32 using cricket::Candidate; |
| 33 using cricket::Candidates; | 33 using cricket::Candidates; |
| 34 using cricket::FakeTransportChannel; | 34 using cricket::FakeTransportChannel; |
| (...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 676 // new --> gathering --> complete | 676 // new --> gathering --> complete |
| 677 EXPECT_EQ_WAIT(cricket::kIceGatheringComplete, gathering_state_, kTimeout); | 677 EXPECT_EQ_WAIT(cricket::kIceGatheringComplete, gathering_state_, kTimeout); |
| 678 EXPECT_EQ(2, gathering_state_signal_count_); | 678 EXPECT_EQ(2, gathering_state_signal_count_); |
| 679 | 679 |
| 680 EXPECT_EQ_WAIT(1U, candidates_["audio"].size(), kTimeout); | 680 EXPECT_EQ_WAIT(1U, candidates_["audio"].size(), kTimeout); |
| 681 EXPECT_EQ_WAIT(1U, candidates_["video"].size(), kTimeout); | 681 EXPECT_EQ_WAIT(1U, candidates_["video"].size(), kTimeout); |
| 682 EXPECT_EQ(2, candidates_signal_count_); | 682 EXPECT_EQ(2, candidates_signal_count_); |
| 683 | 683 |
| 684 EXPECT_TRUE(!signaled_on_non_signaling_thread_); | 684 EXPECT_TRUE(!signaled_on_non_signaling_thread_); |
| 685 } | 685 } |
| OLD | NEW |