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

Side by Side Diff: chrome/installer/setup/install_unittest.cc

Issue 2073123003: Update Windows start menu art (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix sprintf Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | win8/resources/Logo.png » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/installer/setup/install.h" 5 #include "chrome/installer/setup/install.h"
6 6
7 #include <objbase.h> 7 #include <objbase.h>
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 305
306 std::string read_manifest; 306 std::string read_manifest;
307 ASSERT_TRUE(base::ReadFileToString(manifest_path_, &read_manifest)); 307 ASSERT_TRUE(base::ReadFileToString(manifest_path_, &read_manifest));
308 308
309 static const char kExpectedManifest[] = 309 static const char kExpectedManifest[] =
310 "<Application xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>\r\n" 310 "<Application xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>\r\n"
311 " <VisualElements\r\n" 311 " <VisualElements\r\n"
312 " ShowNameOnSquare150x150Logo='on'\r\n" 312 " ShowNameOnSquare150x150Logo='on'\r\n"
313 " Square150x150Logo='0.0.0.0\\VisualElements\\Logo.png'\r\n" 313 " Square150x150Logo='0.0.0.0\\VisualElements\\Logo.png'\r\n"
314 " Square70x70Logo='0.0.0.0\\VisualElements\\SmallLogo.png'\r\n" 314 " Square70x70Logo='0.0.0.0\\VisualElements\\SmallLogo.png'\r\n"
315 " Square44x44Logo='0.0.0.0\\VisualElements\\SmallLogo.png'\r\n"
315 " ForegroundText='light'\r\n" 316 " ForegroundText='light'\r\n"
316 " BackgroundColor='#323232'/>\r\n" 317 " BackgroundColor='#212121'/>\r\n"
317 "</Application>\r\n"; 318 "</Application>\r\n";
318 319
319 ASSERT_STREQ(kExpectedManifest, read_manifest.c_str()); 320 ASSERT_STREQ(kExpectedManifest, read_manifest.c_str());
320 } 321 }
321 322
322 TEST_F(InstallShortcutTest, CreateAllShortcuts) { 323 TEST_F(InstallShortcutTest, CreateAllShortcuts) {
323 installer::CreateOrUpdateShortcuts( 324 installer::CreateOrUpdateShortcuts(
324 chrome_exe_, *product_, *prefs_, installer::CURRENT_USER, 325 chrome_exe_, *product_, *prefs_, installer::CURRENT_USER,
325 installer::INSTALL_SHORTCUT_CREATE_ALL); 326 installer::INSTALL_SHORTCUT_CREATE_ALL);
326 base::win::ValidateShortcut(user_desktop_shortcut_, expected_properties_); 327 base::win::ValidateShortcut(user_desktop_shortcut_, expected_properties_);
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after
813 installer::EscapeXmlAttributeValueInSingleQuotes(&val); 814 installer::EscapeXmlAttributeValueInSingleQuotes(&val);
814 ASSERT_STREQ(kExpectedEscapedVal, val.c_str()); 815 ASSERT_STREQ(kExpectedEscapedVal, val.c_str());
815 } 816 }
816 817
817 TEST(EscapeXmlAttributeValueTest, DontEscapeNormalValue) { 818 TEST(EscapeXmlAttributeValueTest, DontEscapeNormalValue) {
818 base::string16 val(L"Google Chrome"); 819 base::string16 val(L"Google Chrome");
819 static const wchar_t kExpectedEscapedVal[] = L"Google Chrome"; 820 static const wchar_t kExpectedEscapedVal[] = L"Google Chrome";
820 installer::EscapeXmlAttributeValueInSingleQuotes(&val); 821 installer::EscapeXmlAttributeValueInSingleQuotes(&val);
821 ASSERT_STREQ(kExpectedEscapedVal, val.c_str()); 822 ASSERT_STREQ(kExpectedEscapedVal, val.c_str());
822 } 823 }
OLDNEW
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | win8/resources/Logo.png » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698