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

Side by Side Diff: chrome/browser/autofill/data_driven_test.cc

Issue 6733055: Add SCOPED_TRACE to data driven tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/browser/autofill/data_driven_test.h" 5 #include "chrome/browser/autofill/data_driven_test.h"
6 6
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "chrome/common/chrome_paths.h" 10 #include "chrome/common/chrome_paths.h"
(...skipping 25 matching lines...) Expand all
36 const FilePath& output_directory, 36 const FilePath& output_directory,
37 const FilePath::StringType& file_name_pattern) { 37 const FilePath::StringType& file_name_pattern) {
38 file_util::FileEnumerator input_files(input_directory, 38 file_util::FileEnumerator input_files(input_directory,
39 false, 39 false,
40 file_util::FileEnumerator::FILES, 40 file_util::FileEnumerator::FILES,
41 file_name_pattern); 41 file_name_pattern);
42 42
43 for (FilePath input_file = input_files.Next(); 43 for (FilePath input_file = input_files.Next();
44 !input_file.empty(); 44 !input_file.empty();
45 input_file = input_files.Next()) { 45 input_file = input_files.Next()) {
46 SCOPED_TRACE(input_file.BaseName().value());
47
46 std::string input; 48 std::string input;
47 ASSERT_TRUE(ReadFile(input_file, &input)); 49 ASSERT_TRUE(ReadFile(input_file, &input));
48 50
49 std::string output; 51 std::string output;
50 GenerateResults(input, &output); 52 GenerateResults(input, &output);
51 53
52 FilePath output_file = output_directory.Append( 54 FilePath output_file = output_directory.Append(
53 input_file.BaseName().StripTrailingSeparators().ReplaceExtension( 55 input_file.BaseName().StripTrailingSeparators().ReplaceExtension(
54 FILE_PATH_LITERAL(".out"))); 56 FILE_PATH_LITERAL(".out")));
55 57
(...skipping 23 matching lines...) Expand all
79 .Append(test_name) 81 .Append(test_name)
80 .AppendASCII("output"); 82 .AppendASCII("output");
81 return test_data_dir_; 83 return test_data_dir_;
82 } 84 }
83 85
84 DataDrivenTest::DataDrivenTest() { 86 DataDrivenTest::DataDrivenTest() {
85 } 87 }
86 88
87 DataDrivenTest::~DataDrivenTest() { 89 DataDrivenTest::~DataDrivenTest() {
88 } 90 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698