summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/history/multiple-classes-visited.html
blob: ebbc24c18e0b9be4cfb991514ff9700c7d65d4fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<html>
<head>
<script src="../../resources/js-test.js"></script>
<script>
jsTestIsAsync = true;

if (window.testRunner)
    window.testRunner.keepWebHistory();

function compareStyles()
{
    if (window.internals) {
        firstStyle = internals.computedStyleIncludingVisitedInfo(document.getElementById('one'));
        secondStyle = internals.computedStyleIncludingVisitedInfo(document.getElementById('two'));
        shouldBecomeEqual('firstStyle.color', 'secondStyle.color', finishJSTest);
    }
}
</script>
<style>
#one:link { color: green }
#two:link { color: purple }
#one:visited { color: orange }
#two.test:visited { color: orange }
</style>
</head>
<body onload="compareStyles()">
<iframe src="resources/dummy.html" style="display:none"></iframe>
<p>These two links should be the same color (orange):</p>
<p>
  <a href="resources/dummy.html" id="one">One</a>
  <a href="resources/dummy.html" id="two" class="test">Two</a><br>
</p>
<div id=console></div>
</body>
</html>