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
3 // found in the LICENSE file.
5 #ifndef CHROME_COMMON_EXTENSIONS_EXTENSION_TEST_UTIL_H_
6 #define CHROME_COMMON_EXTENSIONS_EXTENSION_TEST_UTIL_H_
10 #include "base/memory/ref_counted.h"
11 #include "extensions/common/manifest.h"
13 namespace extensions
{
17 // Newer functions go in extensions/common/test_util.h.
18 namespace extension_test_util
{
20 // Helpers for loading manifests, |dir| is relative to chrome::DIR_TEST_DATA
21 // followed by "extensions".
22 scoped_refptr
<extensions::Extension
> LoadManifestUnchecked(
23 const std::string
& dir
,
24 const std::string
& test_file
,
25 extensions::Manifest::Location location
,
27 const std::string
& id
,
30 scoped_refptr
<extensions::Extension
> LoadManifestUnchecked(
31 const std::string
& dir
,
32 const std::string
& test_file
,
33 extensions::Manifest::Location location
,
37 scoped_refptr
<extensions::Extension
> LoadManifest(
38 const std::string
& dir
,
39 const std::string
& test_file
,
40 extensions::Manifest::Location location
,
43 scoped_refptr
<extensions::Extension
> LoadManifest(const std::string
& dir
,
44 const std::string
& test_file
,
47 scoped_refptr
<extensions::Extension
> LoadManifestStrict(
48 const std::string
& dir
,
49 const std::string
& test_file
);
51 scoped_refptr
<extensions::Extension
> LoadManifest(const std::string
& dir
,
52 const std::string
& test_file
);
54 } // namespace extension_test_util
56 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_TEST_UTIL_H_