aboutsummaryrefslogtreecommitdiffhomepage
path: root/caddytest/integration/caddyfile_adapt/push.caddyfiletest
diff options
context:
space:
mode:
Diffstat (limited to 'caddytest/integration/caddyfile_adapt/push.caddyfiletest')
-rw-r--r--caddytest/integration/caddyfile_adapt/push.caddyfiletest78
1 files changed, 78 insertions, 0 deletions
diff --git a/caddytest/integration/caddyfile_adapt/push.caddyfiletest b/caddytest/integration/caddyfile_adapt/push.caddyfiletest
new file mode 100644
index 000000000..1fe344e09
--- /dev/null
+++ b/caddytest/integration/caddyfile_adapt/push.caddyfiletest
@@ -0,0 +1,78 @@
+:80
+
+push * /foo.txt
+
+push {
+ GET /foo.txt
+}
+
+push {
+ GET /foo.txt
+ HEAD /foo.txt
+}
+
+push {
+ headers {
+ Foo bar
+ }
+}
+----------
+{
+ "apps": {
+ "http": {
+ "servers": {
+ "srv0": {
+ "listen": [
+ ":80"
+ ],
+ "routes": [
+ {
+ "handle": [
+ {
+ "handler": "push",
+ "resources": [
+ {
+ "target": "/foo.txt"
+ }
+ ]
+ },
+ {
+ "handler": "push",
+ "resources": [
+ {
+ "method": "GET",
+ "target": "/foo.txt"
+ }
+ ]
+ },
+ {
+ "handler": "push",
+ "resources": [
+ {
+ "method": "GET",
+ "target": "/foo.txt"
+ },
+ {
+ "method": "HEAD",
+ "target": "/foo.txt"
+ }
+ ]
+ },
+ {
+ "handler": "push",
+ "headers": {
+ "set": {
+ "Foo": [
+ "bar"
+ ]
+ }
+ }
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+ }
+} \ No newline at end of file