| OLD | NEW |
| 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 "base/files/file_path.h" | 5 #include "base/files/file_path.h" |
| 6 #include "base/files/file_util.h" | 6 #include "base/files/file_util.h" |
| 7 #include "base/json/json_file_value_serializer.h" | 7 #include "base/json/json_file_value_serializer.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 } | 73 } |
| 74 | 74 |
| 75 JSONFileValueDeserializer deserializer(manifest); | 75 JSONFileValueDeserializer deserializer(manifest); |
| 76 std::string error; | 76 std::string error; |
| 77 scoped_ptr<base::DictionaryValue> root(static_cast<base::DictionaryValue*>( | 77 scoped_ptr<base::DictionaryValue> root(static_cast<base::DictionaryValue*>( |
| 78 deserializer.Deserialize(NULL, &error))); | 78 deserializer.Deserialize(NULL, &error))); |
| 79 ASSERT_TRUE(root); | 79 ASSERT_TRUE(root); |
| 80 ASSERT_TRUE(root->IsType(base::Value::TYPE_DICTIONARY)); | 80 ASSERT_TRUE(root->IsType(base::Value::TYPE_DICTIONARY)); |
| 81 | 81 |
| 82 // This checks that the whole manifest is compatible. | 82 // This checks that the whole manifest is compatible. |
| 83 base::Version version; | 83 Version version; |
| 84 EXPECT_TRUE(chrome::CheckPepperFlashManifest(*root, &version)); | 84 EXPECT_TRUE(chrome::CheckPepperFlashManifest(*root, &version)); |
| 85 EXPECT_TRUE(version.IsValid()); | 85 EXPECT_TRUE(version.IsValid()); |
| 86 } | 86 } |
| 87 | 87 |
| 88 } // namespace component_updater | 88 } // namespace component_updater |
| OLD | NEW |