1<html lang="en">
2
3<head>
4    <title>Test page</title>
5    <script>
6        let JSINFO = {};
7        JSINFO.ga = {};
8        JSINFO.ga.trackingId = 'UA-XXXXXXX-1';
9        JSINFO.ga.trackOutboundLinks = true;
10        JSINFO.ga.debug = true;
11    </script>
12    <script charset="utf-8" src="https://code.jquery.com/jquery-3.5.0.min.js"></script>
13    <script src="script.js"></script>
14</head>
15
16<body>
17    <h1>Test Page</h1>
18    <p>This is a page that supports testing purpose</p>
19
20    <h2>Prerequisites</h2>
21
22    Start a web server to serve this page.
23
24    Example with browser-sync
25    <pre>
26browser-sync start --server --port 3000 --startPath test.html
27</pre>
28
29
30    <h2>Test</h2>
31    <h3>New tab test</h3>
32
33    <ul>
34        <li>Test Description: A click on <a href="https://dokuwiki.org" class="urlextern" target="_blank">this Dokuwiki
35                link</a> should
36            navigate to another tab because of the <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attr-target">target value of blank</a>
37        </li>
38        <li>Check steps:
39            <ul>
40                <li>Open the devtool console</li>
41                <li>Click the link</li>
42                <li>Check that a new tab was opened</li>
43                <li>Check that the hit payload is shown in the console</li>
44            </ul>
45        </li>
46    </ul>
47    <h3>Same tab test</h3>
48    <ul>
49        <li>Test: A click on <a href="https://dokuwiki.org" class="urlextern">this Dokuwiki link</a> should
50            navigate in the same tab.
51        </li>
52        <li>Check steps:
53            <ul>
54                <li>Open the browser devtool</li>
55                <li>Go to the network tab</li>
56                <li>Check `Preserve log` to preserve the log between pages reload</li>
57                <li>Clear the network log</li>
58                <li>While clicking the link, check the console, you should see briefly the hit</li>
59                <li>Check the first item of the network log</li>
60                <li>Grab the hit (ie</li>
61                <li>Go to <a href="https://ga-dev-tools.appspot.com/hit-builder/">hit builder</a> and validate the hit</li>
62                <li>The hit should not be valid because of the tid. The `ec` parameter should show a `outbound` value</li>
63            </ul>
64        </li>
65
66    </ul>
67
68</body>
69
70</html>