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

Side by Side Diff: components/omnibox/keyword_provider_unittest.cc

Issue 684513002: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 1 month 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
OLDNEW
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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/message_loop/message_loop.h" 6 #include "base/message_loop/message_loop.h"
7 #include "base/strings/utf_string_conversions.h" 7 #include "base/strings/utf_string_conversions.h"
8 #include "components/metrics/proto/omnibox_event.pb.h" 8 #include "components/metrics/proto/omnibox_event.pb.h"
9 #include "components/omnibox/autocomplete_match.h" 9 #include "components/omnibox/autocomplete_match.h"
10 #include "components/omnibox/autocomplete_scheme_classifier.h" 10 #include "components/omnibox/autocomplete_scheme_classifier.h"
(...skipping 29 matching lines...) Expand all
40 }; 40 };
41 41
42 template<class ResultType> 42 template<class ResultType>
43 struct TestData { 43 struct TestData {
44 const base::string16 input; 44 const base::string16 input;
45 const size_t num_results; 45 const size_t num_results;
46 const MatchType<ResultType> output[3]; 46 const MatchType<ResultType> output[3];
47 }; 47 };
48 48
49 KeywordProviderTest() : kw_provider_(NULL) { } 49 KeywordProviderTest() : kw_provider_(NULL) { }
50 virtual ~KeywordProviderTest() { } 50 ~KeywordProviderTest() override {}
51 51
52 virtual void SetUp(); 52 void SetUp() override;
53 virtual void TearDown(); 53 void TearDown() override;
54 54
55 template<class ResultType> 55 template<class ResultType>
56 void RunTest(TestData<ResultType>* keyword_cases, 56 void RunTest(TestData<ResultType>* keyword_cases,
57 int num_cases, 57 int num_cases,
58 ResultType AutocompleteMatch::* member); 58 ResultType AutocompleteMatch::* member);
59 59
60 protected: 60 protected:
61 static const TemplateURLService::Initializer kTestData[]; 61 static const TemplateURLService::Initializer kTestData[];
62 62
63 scoped_refptr<KeywordProvider> kw_provider_; 63 scoped_refptr<KeywordProvider> kw_provider_;
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 TestData<GURL> url_cases[] = { 360 TestData<GURL> url_cases[] = {
361 { ASCIIToUTF16("a 1 2 3"), 3, 361 { ASCIIToUTF16("a 1 2 3"), 3,
362 { { GURL("aa.com?a=b&foo=1+2+3"), false }, 362 { { GURL("aa.com?a=b&foo=1+2+3"), false },
363 { GURL("bogus URL 1+2+3"), false }, 363 { GURL("bogus URL 1+2+3"), false },
364 { GURL("http://aaaa/?aaaa=1&b=1+2+3&c"), false } } }, 364 { GURL("http://aaaa/?aaaa=1&b=1+2+3&c"), false } } },
365 }; 365 };
366 366
367 RunTest<GURL>(url_cases, arraysize(url_cases), 367 RunTest<GURL>(url_cases, arraysize(url_cases),
368 &AutocompleteMatch::destination_url); 368 &AutocompleteMatch::destination_url);
369 } 369 }
OLDNEW
« no previous file with comments | « components/omnibox/base_search_provider_unittest.cc ('k') | components/os_crypt/os_crypt_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698