OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "core/css/cssom/CSSStyleVariableReferenceValue.h" | 5 #include "core/css/cssom/CSSStyleVariableReferenceValue.h" |
6 | 6 |
7 #include "core/css/cssom/CSSUnparsedValue.h" | 7 #include "core/css/cssom/CSSUnparsedValue.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
9 | 9 |
10 namespace blink { | 10 namespace blink { |
| 11 namespace cssom { |
11 | 12 |
12 namespace { | 13 namespace { |
13 | 14 |
14 StringOrCSSVariableReferenceValue getStringOrCSSVariableReferenceValue(String st
r) | 15 StringOrCSSVariableReferenceValue getStringOrCSSVariableReferenceValue(String st
r) |
15 { | 16 { |
16 StringOrCSSVariableReferenceValue temp; | 17 StringOrCSSVariableReferenceValue temp; |
17 temp.setString(str); | 18 temp.setString(str); |
18 return temp; | 19 return temp; |
19 } | 20 } |
20 | 21 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 CSSUnparsedValue* unparsedValue = CSSUnparsedValue::create(fragments); | 60 CSSUnparsedValue* unparsedValue = CSSUnparsedValue::create(fragments); |
60 | 61 |
61 CSSStyleVariableReferenceValue* ref = CSSStyleVariableReferenceValue::create
("test", unparsedValue); | 62 CSSStyleVariableReferenceValue* ref = CSSStyleVariableReferenceValue::create
("test", unparsedValue); |
62 | 63 |
63 EXPECT_EQ(ref->variable(), "test"); | 64 EXPECT_EQ(ref->variable(), "test"); |
64 EXPECT_EQ(ref->fallback(), unparsedValue); | 65 EXPECT_EQ(ref->fallback(), unparsedValue); |
65 } | 66 } |
66 | 67 |
67 } // namespace | 68 } // namespace |
68 | 69 |
| 70 } // namespace cssom |
69 } // namespace blink | 71 } // namespace blink |
| 72 |
OLD | NEW |