From c04e82263d3d9e097ee1335f330e7e832c0f7bb8 Mon Sep 17 00:00:00 2001 From: igor Date: Tue, 30 Aug 2016 23:53:59 +0300 Subject: [PATCH] CORS header test, fix grep --- dbms/tests/queries/0_stateless/00372_cors_header.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dbms/tests/queries/0_stateless/00372_cors_header.sh b/dbms/tests/queries/0_stateless/00372_cors_header.sh index 3b3e2857240..bdcff850fca 100755 --- a/dbms/tests/queries/0_stateless/00372_cors_header.sh +++ b/dbms/tests/queries/0_stateless/00372_cors_header.sh @@ -1,4 +1,4 @@ -curl -vsS 'http://localhost:8123/?add_http_cors_header=1' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep "< Access-Control-Allow-Origin: *" | wc -l -curl -vsS 'http://localhost:8123/?add_http_cors_header=0' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep "< Access-Control-Allow-Origin: *" | wc -l -curl -vsS 'http://localhost:8123/' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep "< Access-Control-Allow-Origin: *" | wc -l -curl -vsS 'http://localhost:8123/?add_http_cors_header=1' --data-binary @- <<< "SELECT 1" 2>&1 | grep "< Access-Control-Allow-Origin: *" | wc -l \ No newline at end of file +curl -vsS 'http://localhost:8123/?add_http_cors_header=1' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep -F "< Access-Control-Allow-Origin: *" | wc -l +curl -vsS 'http://localhost:8123/?add_http_cors_header=0' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep -F "< Access-Control-Allow-Origin: *" | wc -l +curl -vsS 'http://localhost:8123/' -H "Origin:smi2.ru" --data-binary @- <<< "SELECT 1" 2>&1 | grep -F "< Access-Control-Allow-Origin: *" | wc -l +curl -vsS 'http://localhost:8123/?add_http_cors_header=1' --data-binary @- <<< "SELECT 1" 2>&1 | grep -F "< Access-Control-Allow-Origin: *" | wc -l