1 /* $Id: test_ses_map.cpp,v 1.4 2006-06-10 14:29:13 adam Exp $
2 Copyright (c) 2005-2006, Index Data.
4 See the LICENSE file for details
12 #include "session.hpp"
13 #include "package.hpp"
17 #include <boost/thread.hpp>
18 #include <boost/shared_ptr.hpp>
19 #define BOOST_AUTO_TEST_MAIN
20 #include <boost/test/auto_unit_test.hpp>
23 #include <yaz/pquery.h>
24 #include <yaz/otherinfo.h>
25 using namespace boost::unit_test;
27 namespace mp = metaproxy_1;
29 namespace metaproxy_1 {
36 Wrap(const double &t) : m_t(t) { };
41 boost::mutex m_map_mutex;
43 void create(SesMap &sm, const mp::Session &s, double &t) {
44 boost::mutex::scoped_lock lock(m_map_mutex);
46 boost::shared_ptr<Wrap> w_ptr(new Wrap(t));
49 std::map<mp::Session,boost::shared_ptr<Wrap> >m_map_ptr;
54 BOOST_AUTO_UNIT_TEST( test_ses_map_1 )
69 * indent-tabs-mode: nil
70 * c-file-style: "stroustrup"
72 * vim: shiftwidth=4 tabstop=8 expandtab