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

Unified Diff: chrome/utility/extensions/unpacker_unittest.cc

Issue 635623003: Cleanup: Better constify some strings in chrome. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix mac Created 6 years, 2 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/utility/cloud_print/pwg_encoder.cc ('k') | chrome/utility/importer/firefox_importer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/utility/extensions/unpacker_unittest.cc
diff --git a/chrome/utility/extensions/unpacker_unittest.cc b/chrome/utility/extensions/unpacker_unittest.cc
index abf6b75985d8954dfc6e27ae0759eea867928d5c..99939f13658886af2c3b2eaa357a565608f77268 100644
--- a/chrome/utility/extensions/unpacker_unittest.cc
+++ b/chrome/utility/extensions/unpacker_unittest.cc
@@ -132,7 +132,7 @@ TEST_F(UnpackerTest, NoL10n) {
}
TEST_F(UnpackerTest, UnzipDirectoryError) {
- const char* kExpected = "Could not create directory for unzipping: ";
+ const char kExpected[] = "Could not create directory for unzipping: ";
SetupUnpacker("good_package.crx");
base::FilePath path =
temp_dir_.path().AppendASCII(kTempExtensionName);
@@ -146,14 +146,14 @@ TEST_F(UnpackerTest, UnzipDirectoryError) {
}
TEST_F(UnpackerTest, UnzipError) {
- const char* kExpected = "Could not unzip extension";
+ const char kExpected[] = "Could not unzip extension";
SetupUnpacker("bad_zip.crx");
EXPECT_FALSE(unpacker_->Run());
EXPECT_EQ(ASCIIToUTF16(kExpected), unpacker_->error_message());
}
TEST_F(UnpackerTest, BadPathError) {
- const char* kExpected = "Illegal path (absolute or relative with '..'): ";
+ const char kExpected[] = "Illegal path (absolute or relative with '..'): ";
SetupUnpacker("bad_path.crx");
EXPECT_FALSE(unpacker_->Run());
EXPECT_TRUE(StartsWith(unpacker_->error_message(),
@@ -165,7 +165,7 @@ TEST_F(UnpackerTest, BadPathError) {
TEST_F(UnpackerTest, ImageDecodingError) {
- const char* kExpected = "Could not decode image: ";
+ const char kExpected[] = "Could not decode image: ";
SetupUnpacker("bad_image.crx");
EXPECT_FALSE(unpacker_->Run());
EXPECT_TRUE(StartsWith(unpacker_->error_message(),
« no previous file with comments | « chrome/utility/cloud_print/pwg_encoder.cc ('k') | chrome/utility/importer/firefox_importer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698