X-Git-Url: http://sru.miketaylor.org.uk/?a=blobdiff_plain;f=src%2Ftest_filter_rewrite.cpp;h=1f86a98b3e2bcca71c02f15fc0d9eadd6124a8c3;hb=489bd9188aed44d93c29f996311e0477152d592a;hp=65cb4c08fd140425d27b20e258c2f62debea150e;hpb=8bcd4c3e063e932b2f80f9491ec0af66d3da5c2e;p=metaproxy-moved-to-github.git diff --git a/src/test_filter_rewrite.cpp b/src/test_filter_rewrite.cpp index 65cb4c0..1f86a98 100644 --- a/src/test_filter_rewrite.cpp +++ b/src/test_filter_rewrite.cpp @@ -38,29 +38,11 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA using namespace boost::unit_test; namespace mp = metaproxy_1; -/* - * The global testconfig is commented out, as it won't even compile - * on old Centos5 machines -struct TestConfig { - TestConfig() - { - std::cout << "global setup\n"; - yaz_log_init_level(YLOG_ALL); - } - ~TestConfig() - { - std::cout << "global teardown\n"; - } -}; - -BOOST_GLOBAL_FIXTURE( TestConfig ); -*/ 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; @@ -68,30 +50,45 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) "\n" "\n" - " \n" - " \n" - " \n" + " \n" + " \n" + " \n" " \n" " \n" - " \n" - " \n" - " \n" + " \n" + " \n" + " \n" + " \n" + " \n" " \n" - " \n" - " \n" - " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" " \n" " \n" - " \n" - " \n" - " \n" - " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" + " \n" " \n" "\n" ; @@ -120,7 +117,6 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) const char *resp_buf = "HTTP/1.1 200 OK\r\n" - "Content-Length: 441\r\n" "Content-Type: text/html\r\n" "Link: ; rel=absolute\r\n" "Link: ; rel=relative\r\n" @@ -132,7 +128,10 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) "}" "" "" - "" + "" "" "Welcome to our website. It doesn't make it easy to get pro" "xified" @@ -141,11 +140,13 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) "" " Another abs link" "" + "" + "" "
Welcome to our website. It doesn't make it easy to get pro" "xified" @@ -141,11 +140,13 @@ BOOST_AUTO_TEST_CASE( test_filter_rewrite_1 ) "" " Another abs link" "" + "" + "" "