diff options
Diffstat (limited to 'brokenlinks/testdata')
| -rw-r--r-- | brokenlinks/testdata/past_result.json | 10 | ||||
| -rw-r--r-- | brokenlinks/testdata/past_result.json.license | 2 | ||||
| -rw-r--r-- | brokenlinks/testdata/web/broken.html | 7 | ||||
| -rw-r--r-- | brokenlinks/testdata/web/gopher.png | bin | 0 -> 32775 bytes | |||
| -rw-r--r-- | brokenlinks/testdata/web/index.html | 22 | ||||
| -rw-r--r-- | brokenlinks/testdata/web/page2/index.html | 14 |
6 files changed, 55 insertions, 0 deletions
diff --git a/brokenlinks/testdata/past_result.json b/brokenlinks/testdata/past_result.json new file mode 100644 index 0000000..ca29d35 --- /dev/null +++ b/brokenlinks/testdata/past_result.json @@ -0,0 +1,10 @@ +{ + "broken_links": { + "http://127.0.0.1:11836/page2": [ + { + "link": "http://127.0.0.1:11836/", + "code": 404 + } + ] + } +} diff --git a/brokenlinks/testdata/past_result.json.license b/brokenlinks/testdata/past_result.json.license new file mode 100644 index 0000000..22616a9 --- /dev/null +++ b/brokenlinks/testdata/past_result.json.license @@ -0,0 +1,2 @@ +SPDX-FileCopyrightText: 2025 M. Shulhan <ms@kilabit.info> +SPDX-License-Identifier: GPL-3.0-only diff --git a/brokenlinks/testdata/web/broken.html b/brokenlinks/testdata/web/broken.html new file mode 100644 index 0000000..533e542 --- /dev/null +++ b/brokenlinks/testdata/web/broken.html @@ -0,0 +1,7 @@ +<html> + <head></head> + <body> + <a href="/brokenPage" + <p> + </body> +</html> diff --git a/brokenlinks/testdata/web/gopher.png b/brokenlinks/testdata/web/gopher.png Binary files differnew file mode 100644 index 0000000..79352be --- /dev/null +++ b/brokenlinks/testdata/web/gopher.png diff --git a/brokenlinks/testdata/web/index.html b/brokenlinks/testdata/web/index.html new file mode 100644 index 0000000..61a1f39 --- /dev/null +++ b/brokenlinks/testdata/web/index.html @@ -0,0 +1,22 @@ +<!-- +SPDX-FileCopyrightText: 2025 M. Shulhan <ms@kilabit.info> +SPDX-License-Identifier: GPL-3.0-only +--> +<html> + <body> + <img src="/broken.png" /> + <a href="/brokenPage">Broken page</a> + <img src="/gopher.png" /> + <img width="200" src="" /> + <a href="/page2">Page 2</a> + <a href="/broken.html">Broken HTML</a> + <a href="http://127.0.0.1:11900">External URL</a> + <!-- Error when fetching with GET --> + <a href="http:/127.0.0.1:11836">Invalid external URL</a> + <!-- Error when parsing URL --> + <a href="http://127.0.0.1:abc">Invalid URL port</a> + <!-- Fragment should be skipped and cleaned up --> + <a href="#goto_a">Same with href to "/"</a> + <a href="/page2#goto_a">Same with href to "/page2"</a> + </body> +</html> diff --git a/brokenlinks/testdata/web/page2/index.html b/brokenlinks/testdata/web/page2/index.html new file mode 100644 index 0000000..ae6b4ea --- /dev/null +++ b/brokenlinks/testdata/web/page2/index.html @@ -0,0 +1,14 @@ +<!-- +SPDX-FileCopyrightText: 2025 M. Shulhan <ms@kilabit.info> +SPDX-License-Identifier: GPL-3.0-only +--> +<html> + <body> + <img src="/broken.png" /> + <img src="broken2.png" /> + <a href="broken/relative">broken relative link</a> + <a href="/">Back with absolute path</a> + <a href="../">Back with relative path</a> + <a href="http://127.0.0.1:11900/page2">External URL page2</a> + </body> +</html> |
