Chromium Code Reviews| Index: chrome/common/extensions/manifest_tests/extension_manifest_test.h |
| diff --git a/chrome/common/extensions/manifest_tests/extension_manifest_test.h b/chrome/common/extensions/manifest_tests/extension_manifest_test.h |
| index d7169437cb4fb525a8747fef933662ee83ea04d7..bb0af6a1589963926ab9bdda93dca3af377931a4 100644 |
| --- a/chrome/common/extensions/manifest_tests/extension_manifest_test.h |
| +++ b/chrome/common/extensions/manifest_tests/extension_manifest_test.h |
| @@ -42,12 +42,25 @@ class ExtensionManifestTest : public testing::Test { |
| base::DictionaryValue* GetManifest(char const* test_data_dir, |
| std::string* error) const; |
| - private: |
| + protected: |
| const std::string name_; |
| mutable base::DictionaryValue* manifest_; |
| mutable scoped_ptr<base::DictionaryValue> manifest_holder_; |
| }; |
| + // Helper class creating a Manifest object from a string. For readability |
| + // single quotes are replaced with double quotes. |
| + // E.g. ManifestFromString("{ 'name': 'a' }") parses JSON { "name": "a" }. |
| + class ManifestFromString : public Manifest { |
|
Jeffrey Yasskin
2014/02/28 01:54:37
It'd be nice to make this Just Work for Manifest,
scheib
2014/02/28 04:16:07
Constructor overloaded would be nice - but I don't
|
| + public: |
| + explicit ManifestFromString( |
| + const char* manifest_as_string_with_single_quotes); |
| + ~ManifestFromString(); |
| + |
| + protected: |
| + scoped_ptr<base::Value> parsed_manifest_holder_; |
| + }; |
| + |
| // The subdirectory in which to find test data files. |
| virtual char const* test_data_dir(); |