| Index: chrome/browser/webdata/web_data_service_unittest.cc
|
| diff --git a/chrome/browser/webdata/web_data_service_unittest.cc b/chrome/browser/webdata/web_data_service_unittest.cc
|
| index 5c439db286407950772ecc04351d33fa21aadb94..bc11e48e99e0dc0db408f55ed68ae586b462b75c 100644
|
| --- a/chrome/browser/webdata/web_data_service_unittest.cc
|
| +++ b/chrome/browser/webdata/web_data_service_unittest.cc
|
| @@ -638,3 +638,27 @@ TEST_F(WebDataServiceTest, WebIntents) {
|
| EXPECT_EQ(intent.type, consumer.intents[0].type);
|
| }
|
|
|
| +TEST_F(WebDataServiceTest, WebIntentsGetAll) {
|
| + WebIntentsConsumer consumer;
|
| +
|
| + WebIntentData intent;
|
| + intent.service_url = GURL("http://google.com");
|
| + intent.action = ASCIIToUTF16("share");
|
| + intent.type = ASCIIToUTF16("image/*");
|
| + wds_->AddWebIntent(intent);
|
| +
|
| + intent.action = ASCIIToUTF16("edit");
|
| + wds_->AddWebIntent(intent);
|
| +
|
| + wds_->GetAllWebIntents(&consumer);
|
| + WebIntentsConsumer::WaitUntilCalled();
|
| + ASSERT_EQ(2U, consumer.intents.size());
|
| +
|
| + if (consumer.intents[0].action != ASCIIToUTF16("edit"))
|
| + std::swap(consumer.intents[0],consumer.intents[1]);
|
| +
|
| + EXPECT_EQ(intent, consumer.intents[0]);
|
| + intent.action=ASCIIToUTF16("share");
|
| + EXPECT_EQ(intent, consumer.intents[1]);
|
| +}
|
| +
|
|
|