nixos/h2o: reduce variable name noise

+6 -13
+4 -9
nixos/tests/web-servers/h2o/basic.nix
··· 110 110 }; 111 111 }; 112 112 }; 113 - 114 113 testScript = 115 114 let 116 115 portStrHTTP = builtins.toString port.HTTP; ··· 122 121 server.wait_for_open_port(${portStrHTTP}) 123 122 server.wait_for_open_port(${portStrTLS}) 124 123 125 - http_hello_world_body = server.succeed("curl --fail-with-body 'http://${domain.HTTP}:${portStrHTTP}/hello_world.txt'") 126 - assert "${sawatdi_chao_lok}" in http_hello_world_body 124 + assert "${sawatdi_chao_lok}" in server.succeed("curl --fail-with-body 'http://${domain.HTTP}:${portStrHTTP}/hello_world.txt'") 127 125 128 126 tls_hello_world_head = server.succeed("curl -v --head --compressed --http2 --tlsv1.3 --fail-with-body 'https://${domain.TLS}:${portStrTLS}/hello_world.rst'").lower() 129 127 assert "http/2 200" in tls_hello_world_head 130 128 assert "server: h2o" in tls_hello_world_head 131 129 assert "content-type: text/x-rst" in tls_hello_world_head 132 130 133 - tls_hello_world_body = server.succeed("curl -v --http2 --tlsv1.3 --compressed --fail-with-body 'https://${domain.TLS}:${portStrTLS}/hello_world.rst'") 134 - assert "${sawatdi_chao_lok}" in tls_hello_world_body 131 + assert "${sawatdi_chao_lok}" in server.succeed("curl -v --http2 --tlsv1.3 --compressed --fail-with-body 'https://${domain.TLS}:${portStrTLS}/hello_world.rst'") 135 132 136 - tls_hello_world_head_redirected = server.succeed("curl -v --head --fail-with-body 'http://${domain.TLS}:${builtins.toString port.HTTP}/hello_world.rst'").lower() 137 - assert "redirected" in tls_hello_world_head_redirected 133 + assert "redirected" in server.succeed("curl -v --head --fail-with-body 'http://${domain.TLS}:${portStrHTTP}/hello_world.rst'").lower() 138 134 139 135 server.fail("curl --location --max-redirs 0 'http://${domain.TLS}:${portStrHTTP}/hello_world.rst'") 140 136 141 - tls_hello_world_body_redirected = server.succeed("curl -v --location --fail-with-body 'http://${domain.TLS}:${portStrHTTP}/hello_world.rst'") 142 - assert "${sawatdi_chao_lok}" in tls_hello_world_body_redirected 137 + assert "${sawatdi_chao_lok}" in server.succeed("curl -v --location --fail-with-body 'http://${domain.TLS}:${portStrHTTP}/hello_world.rst'") 143 138 ''; 144 139 }
+2 -4
nixos/tests/web-servers/h2o/mruby.nix
··· 58 58 server.wait_for_unit("h2o.service") 59 59 server.wait_for_open_port(${portStr}) 60 60 61 - hello_world = server.succeed("curl --fail-with-body http://${domain}:${portStr}/hello_world") 62 - assert "${sawatdi_chao_lok}" in hello_world 61 + assert "${sawatdi_chao_lok}" in server.succeed("curl --fail-with-body http://${domain}:${portStr}/hello_world") 63 62 64 - file_handler = server.succeed("curl --fail-with-body http://${domain}:${portStr}/file_handler") 65 - assert "FILE_HANDLER" in file_handler 63 + assert "FILE_HANDLER" in server.succeed("curl --fail-with-body http://${domain}:${portStr}/file_handler") 66 64 ''; 67 65 }