Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(334)

Side by Side Diff: chrome/common/extensions/extension_unpacker_unittest.cc

Issue 441008: Many changes to DictionaryValues:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/path_service.h" 6 #include "base/path_service.h"
7 #include "base/string_util.h" 7 #include "base/string_util.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chrome/common/chrome_paths.h" 9 #include "chrome/common/chrome_paths.h"
10 #include "chrome/common/extensions/extension_constants.h" 10 #include "chrome/common/extensions/extension_constants.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 TEST_F(ExtensionUnpackerTest, NoLocaleData) { 100 TEST_F(ExtensionUnpackerTest, NoLocaleData) {
101 SetupUnpacker("no_locale_data.crx"); 101 SetupUnpacker("no_locale_data.crx");
102 EXPECT_FALSE(unpacker_->Run()); 102 EXPECT_FALSE(unpacker_->Run());
103 EXPECT_EQ(errors::kLocalesTreeMissing, unpacker_->error_message()); 103 EXPECT_EQ(errors::kLocalesTreeMissing, unpacker_->error_message());
104 } 104 }
105 105
106 TEST_F(ExtensionUnpackerTest, GoodL10n) { 106 TEST_F(ExtensionUnpackerTest, GoodL10n) {
107 SetupUnpacker("good_l10n.crx"); 107 SetupUnpacker("good_l10n.crx");
108 EXPECT_TRUE(unpacker_->Run()); 108 EXPECT_TRUE(unpacker_->Run());
109 EXPECT_TRUE(unpacker_->error_message().empty()); 109 EXPECT_TRUE(unpacker_->error_message().empty());
110 ASSERT_EQ(2U, unpacker_->parsed_catalogs()->GetSize()); 110 ASSERT_EQ(2U, unpacker_->parsed_catalogs()->size());
111 } 111 }
112 112
113 TEST_F(ExtensionUnpackerTest, NoL10n) { 113 TEST_F(ExtensionUnpackerTest, NoL10n) {
114 SetupUnpacker("no_l10n.crx"); 114 SetupUnpacker("no_l10n.crx");
115 EXPECT_TRUE(unpacker_->Run()); 115 EXPECT_TRUE(unpacker_->Run());
116 EXPECT_TRUE(unpacker_->error_message().empty()); 116 EXPECT_TRUE(unpacker_->error_message().empty());
117 EXPECT_EQ(0U, unpacker_->parsed_catalogs()->GetSize()); 117 EXPECT_EQ(0U, unpacker_->parsed_catalogs()->size());
118 } 118 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698