| Index: third_party/WebKit/LayoutTests/fast/css/pseudo-placeholder.html
|
| diff --git a/third_party/WebKit/LayoutTests/fast/css/pseudo-placeholder.html b/third_party/WebKit/LayoutTests/fast/css/pseudo-placeholder.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..25684f89a198b2655e4efd886e9372fc07f0c416
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/fast/css/pseudo-placeholder.html
|
| @@ -0,0 +1,30 @@
|
| +<!DOCTYPE html>
|
| +<script src="../../resources/testharness.js"></script>
|
| +<script src="../../resources/testharnessreport.js"></script>
|
| +<style>
|
| +input::placeholder:hover {
|
| + color: blue;
|
| +}
|
| +input::placeholder {
|
| + color: green;
|
| +}
|
| +input::-webkit-input-placeholder {
|
| + background: red;
|
| +}
|
| +</style>
|
| +<script>
|
| +test(t => {
|
| + // There are three rules in the style element. But the first one should be
|
| + // dropped.
|
| + assert_equals(document.styleSheets[0].rules.length, 2);
|
| +}, '::placeholder with a user-action selector should be an error.');
|
| +
|
| +test(t => {
|
| + assert_equals(document.styleSheets[0].rules[0].selectorText, 'input::placeholder');
|
| +}, 'Serialization for ::placeholder should be ::placeholder.');
|
| +
|
| +test(t => {
|
| + // Compatibility with Safari and Firefox.
|
| + assert_equals(document.styleSheets[0].rules[1].selectorText, 'input::-webkit-input-placeholder');
|
| +}, 'Serialization for ::-webkit-input-placeholder should be ::-webkit-input-placeholder.');
|
| +</script>
|
|
|