OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "sync/api/attachments/attachment_service_impl.h" | 5 #include "sync/internal_api/public/attachments/attachment_service_impl.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
10 #include "base/run_loop.h" | 10 #include "base/run_loop.h" |
11 #include "sync/internal_api/public/attachments/fake_attachment_downloader.h" | 11 #include "sync/internal_api/public/attachments/fake_attachment_downloader.h" |
12 #include "sync/internal_api/public/attachments/fake_attachment_uploader.h" | 12 #include "sync/internal_api/public/attachments/fake_attachment_uploader.h" |
13 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
14 | 14 |
15 namespace syncer { | 15 namespace syncer { |
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
443 EXPECT_EQ(1U, store()->write_attachments.size()); | 443 EXPECT_EQ(1U, store()->write_attachments.size()); |
444 | 444 |
445 store()->RespondToWrite(AttachmentStore::SUCCESS); | 445 store()->RespondToWrite(AttachmentStore::SUCCESS); |
446 RunLoop(); | 446 RunLoop(); |
447 ASSERT_EQ(1U, store_results().size()); | 447 ASSERT_EQ(1U, store_results().size()); |
448 EXPECT_EQ(AttachmentService::STORE_SUCCESS, store_results()[0]); | 448 EXPECT_EQ(AttachmentService::STORE_SUCCESS, store_results()[0]); |
449 EXPECT_TRUE(on_attachment_uploaded_list().empty()); | 449 EXPECT_TRUE(on_attachment_uploaded_list().empty()); |
450 } | 450 } |
451 | 451 |
452 } // namespace syncer | 452 } // namespace syncer |
OLD | NEW |