1 /* This file is part of Metaproxy.
2 Copyright (C) 2005-2008 Index Data
4 Metaproxy is free software; you can redistribute it and/or modify it under
5 the terms of the GNU General Public License as published by the Free
6 Software Foundation; either version 2, or (at your option) any later
9 Metaproxy is distributed in the hope that it will be useful, but WITHOUT ANY
10 WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24 #include "session.hpp"
25 #include "package.hpp"
29 #include <boost/thread.hpp>
30 #include <boost/shared_ptr.hpp>
31 #define BOOST_AUTO_TEST_MAIN
32 #define BOOST_TEST_DYN_LINK
33 #include <boost/test/auto_unit_test.hpp>
36 #include <yaz/pquery.h>
37 #include <yaz/otherinfo.h>
38 using namespace boost::unit_test;
40 namespace mp = metaproxy_1;
42 namespace metaproxy_1 {
49 Wrap(const double &t) : m_t(t) { };
54 boost::mutex m_map_mutex;
56 void create(SesMap &sm, const mp::Session &s, double &t) {
57 boost::mutex::scoped_lock lock(m_map_mutex);
59 boost::shared_ptr<Wrap> w_ptr(new Wrap(t));
62 std::map<mp::Session,boost::shared_ptr<Wrap> >m_map_ptr;
67 BOOST_AUTO_TEST_CASE( test_ses_map_1 )
82 * c-file-style: "Stroustrup"
83 * indent-tabs-mode: nil
85 * vim: shiftwidth=4 tabstop=8 expandtab