Bug 1018473. Unit test for duplicate trickle candidates. r=bwc

This commit is contained in:
EKR 2014-05-31 12:06:45 -07:00
Родитель 01ccd3683c
Коммит 1ea7cf9b40
1 изменённых файлов: 6 добавлений и 0 удалений

Просмотреть файл

@ -477,6 +477,12 @@ TestObserver::OnIceCandidate(uint16_t level,
{
std::cout << name << ": onIceCandidate [" << level << "/"
<< mid << "] " << candidate << std::endl;
// Check for duplicates.
for (auto it = candidates.begin(); it != candidates.end(); ++it) {
EXPECT_NE(*it, candidate) << "Duplicate candidate";
}
candidates.push_back(candidate);
return NS_OK;
}