X-Git-Url: http://sru.miketaylor.org.uk/?a=blobdiff_plain;f=src%2Ftest_filter_rewrite.cpp;h=110d6144037ec4d8d29d7e92f4fb2990c22fd67f;hb=8ad47a5541b059938d469e47a539762e031e925f;hp=360246a71e620021164f05da8ff7d79cd7798b64;hpb=a8b25eb1e4dee0290182ca69fe49a01557c58811;p=metaproxy-moved-to-github.git diff --git a/src/test_filter_rewrite.cpp b/src/test_filter_rewrite.cpp index 360246a..110d614 100644 --- a/src/test_filter_rewrite.cpp +++ b/src/test_filter_rewrite.cpp @@ -1,5 +1,5 @@ /* This file is part of Metaproxy. - Copyright (C) 2005-2013 Index Data + Copyright (C) Index Data Metaproxy is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free @@ -43,7 +43,6 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) { try { - std::cout << "Running non-xml config test case" << std::endl; mp::RouterChain router; mp::filter::HttpRewrite fhr; @@ -110,8 +109,11 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) mp::odr odr; Z_GDU *gdu_req = z_get_HTTP_Request_uri(odr, - "http://proxyhost/proxypath/targetsite/page1.html", 0, 1); - + "http://proxyhost/proxypath/targetsite/page1.html", 0, 1); + + Z_HTTP_Request *hreq = gdu_req->u.HTTP_Request; + z_HTTP_header_set(odr, &hreq->headers, + "X-Metaproxy-SkipLink", ".* skiplink.com" ); pack.request() = gdu_req; //create the http response @@ -130,6 +132,7 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) "" "" "" "
" @@ -141,12 +144,13 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) " Another abs link" "" "" - "" + "\n" + "skip\n" "