#include <boost/date_time/posix_time/posix_time.hpp>
#include <boost/test/unit_test.hpp>
#include <boost/thread.hpp>
#include <scroom/function-additor.hh>
#include <scroom/semaphore.hh>
#include "helpers.hh"
◆ BOOST_AUTO_TEST_CASE() [1/9]
| BOOST_AUTO_TEST_CASE |
( |
additor_adds |
| ) |
|
◆ BOOST_AUTO_TEST_CASE() [2/9]
| BOOST_AUTO_TEST_CASE |
( |
clear_clears |
| ) |
|
◆ BOOST_AUTO_TEST_CASE() [3/9]
| BOOST_AUTO_TEST_CASE |
( |
destroy_destroys |
| ) |
|
50 boost::shared_ptr<int> p(
new int(4));
51 boost::weak_ptr<int>
const w(p);
54 boost::function<void()>
const f(
destroy(p));
◆ BOOST_AUTO_TEST_CASE() [4/9]
| BOOST_AUTO_TEST_CASE |
( |
left_association |
| ) |
|
◆ BOOST_AUTO_TEST_CASE() [5/9]
| BOOST_AUTO_TEST_CASE |
( |
Multiplier_multiplies |
| ) |
|
132 ((5 *
pass(&s2)) * 5)();
◆ BOOST_AUTO_TEST_CASE() [6/9]
| BOOST_AUTO_TEST_CASE |
( |
order_is_preserved |
| ) |
|
81 BOOST_CHECK(!s1.try_P());
82 BOOST_CHECK(!s2.try_P());
◆ BOOST_AUTO_TEST_CASE() [7/9]
| BOOST_AUTO_TEST_CASE |
( |
pass_passes |
| ) |
|
◆ BOOST_AUTO_TEST_CASE() [8/9]
| BOOST_AUTO_TEST_CASE |
( |
right_association |
| ) |
|
◆ BOOST_AUTO_TEST_CASE() [9/9]
| BOOST_AUTO_TEST_CASE |
( |
Test_If_Expressions_Compile |
| ) |
|
143 (void)(
clear(
nullptr) + (5 *
clear(
nullptr)) * 5);
144 (void)(
clear(
nullptr) + 5 * (5 *
clear(
nullptr)));
145 (void)(4 * (
clear(
nullptr) +
clear(
nullptr)));
146 (void)((
clear(
nullptr) +
clear(
nullptr)) * 4);
◆ long_timeout()
| static const millisec long_timeout |
( |
2000 |
| ) |
|
|
static |
◆ short_timeout()
| static const millisec short_timeout |
( |
250 |
| ) |
|
|
static |
boost::function< void()> clear(Semaphore *s)
Definition: helpers.cc:29
Definition: function-additor.hh:16
BOOST_CHECK_EQUAL(sample.expectedColors, originalColormap->colors.size())
boost::function< void()> destroy(boost::shared_ptr< void > p)
Definition: helpers.cc:31
Definition: semaphore.hh:15
BOOST_REQUIRE(originalColormap)
boost::function< void()> pass(Semaphore *s)
Definition: helpers.cc:27
static const millisec short_timeout(250)
static const millisec long_timeout(2000)