diff options
Diffstat (limited to 'LayoutTests/http/tests/appcache/resources')
9 files changed, 68 insertions, 0 deletions
diff --git a/LayoutTests/http/tests/appcache/resources/document-write-html-element.manifest b/LayoutTests/http/tests/appcache/resources/document-write-html-element.manifest new file mode 100644 index 0000000..af16a0e --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/document-write-html-element.manifest @@ -0,0 +1 @@ +CACHE MANIFEST diff --git a/LayoutTests/http/tests/appcache/resources/fail-on-update-2.html b/LayoutTests/http/tests/appcache/resources/fail-on-update-2.html new file mode 100644 index 0000000..7e78de7 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/fail-on-update-2.html @@ -0,0 +1,7 @@ +<html manifest="fail-on-update-2.php"> +<body> +<script> + top.subframeLoaded(); +</script> +</body> +</html> diff --git a/LayoutTests/http/tests/appcache/resources/fail-on-update-2.php b/LayoutTests/http/tests/appcache/resources/fail-on-update-2.php new file mode 100644 index 0000000..4e11735 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/fail-on-update-2.php @@ -0,0 +1,39 @@ +<?php +require_once '../../resources/portabilityLayer.php'; + +$tmpFile = sys_get_temp_dir() . "/" . "fail_on_update_state"; + +function setState($newState, $file) +{ + file_put_contents($file, $newState); +} + +function getState($file) +{ + if (!file_exists($file)) { + return "Uninitialized"; + } + return file_get_contents($file); +} + +$command = $_GET['command']; +$state = getState($tmpFile); + +header("Expires: Thu, 01 Dec 2003 16:00:00 GMT"); +header("Cache-Control: no-cache, must-revalidate"); +header("Pragma: no-cache"); + +if ($command == "reset") { + unlink($tmpFile); +} else if ($command == "delete") { + setState("Deleted", $tmpFile); +} else if ($state == "Uninitialized") { + header("Content-Type: text/cache-manifest"); + print("CACHE MANIFEST\n"); + print("fail-on-update-2.html\n"); + print("NETWORK:\n"); + print("fail-on-update.php?command=\n"); +} else if ($state == "Deleted") { + header('HTTP/1.0 404 Not Found'); +} +?> diff --git a/LayoutTests/http/tests/appcache/resources/foreign-fallback-fallback.html b/LayoutTests/http/tests/appcache/resources/foreign-fallback-fallback.html new file mode 100644 index 0000000..9996bf6 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/foreign-fallback-fallback.html @@ -0,0 +1,2 @@ +<html manifest="foobar.manifest"> +FAIL diff --git a/LayoutTests/http/tests/appcache/resources/foreign-fallback.manifest b/LayoutTests/http/tests/appcache/resources/foreign-fallback.manifest new file mode 100644 index 0000000..ddaf602 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/foreign-fallback.manifest @@ -0,0 +1,4 @@ +CACHE MANIFEST + +FALLBACK: +/appcache/resources/foreign-fallback/ foreign-fallback-fallback.html diff --git a/LayoutTests/http/tests/appcache/resources/insert-html-element-with-manifest.manifest b/LayoutTests/http/tests/appcache/resources/insert-html-element-with-manifest.manifest new file mode 100644 index 0000000..af16a0e --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/insert-html-element-with-manifest.manifest @@ -0,0 +1 @@ +CACHE MANIFEST diff --git a/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame-2.html b/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame-2.html new file mode 100644 index 0000000..0acc1e2 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame-2.html @@ -0,0 +1,6 @@ +<html manifest="http://127.0.0.1:8000/appcache/resources/main-resource-redirect.manifest"> +<script> +parent.document.getElementById("result").innerHTML = (applicationCache.status) > 0 ? "PASS" : "FAIL: child frame status is UNCACHED"; +parent.done(); + +</script> diff --git a/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame.php b/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame.php new file mode 100644 index 0000000..638057b --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/main-resource-redirect-frame.php @@ -0,0 +1,4 @@ +<?php + header('HTTP/1.0 302 Found'); + header('Location: http://127.0.0.1:8000/resources/network-simulator.php?path=/appcache/resources/main-resource-redirect-frame-2.html'); +?> diff --git a/LayoutTests/http/tests/appcache/resources/main-resource-redirect.manifest b/LayoutTests/http/tests/appcache/resources/main-resource-redirect.manifest new file mode 100644 index 0000000..beffe84 --- /dev/null +++ b/LayoutTests/http/tests/appcache/resources/main-resource-redirect.manifest @@ -0,0 +1,4 @@ +CACHE MANIFEST +http://127.0.0.1:8000/resources/network-simulator.php?path=/appcache/resources/main-resource-redirect-frame-2.html +NETWORK: +http://127.0.0.1:8000/resources/network-simulator.php?command |