From 3e26bef11f77c76e7a0268a19ec309288a21fec1 Mon Sep 17 00:00:00 2001 From: bettafish Date: Wed, 16 Jun 2021 21:19:37 +0200 Subject: [PATCH] vweb: change port for cookie test, fix error reporting --- vlib/vweb/tests/vweb_cookie_test.v | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vlib/vweb/tests/vweb_cookie_test.v b/vlib/vweb/tests/vweb_cookie_test.v index be5bc4a79b..d48b9a592e 100644 --- a/vlib/vweb/tests/vweb_cookie_test.v +++ b/vlib/vweb/tests/vweb_cookie_test.v @@ -2,7 +2,7 @@ import vweb import net.http const ( - port = 8000 + port = 12380 ) struct App { @@ -26,7 +26,7 @@ fn (mut app App) index() vweb.Result { fn test_cookie() { go vweb.run(&App{}, port) - resp := http.get('http://127.0.0.1:$port/') or { panic('server not running') } + resp := http.get('http://127.0.0.1:$port/') or { panic(err) } darkmode := resp.cookies['darkmode'] or { panic('cookie not set') } value := darkmode[0].ascii_str().int() mut path := ''