disable tests requiring logging when building with logging disabled
This commit is contained in:
parent
addc52706e
commit
9d37fbd1f7
|
@ -91,6 +91,7 @@ void run_fake_peer_test(
|
|||
sim.run();
|
||||
}
|
||||
|
||||
#ifndef TORRENT_DISABLE_LOGGING
|
||||
// make sure we consistently send the same allow-fast pieces, regardless
|
||||
// of which pieces the peer has.
|
||||
TORRENT_TEST(allow_fast)
|
||||
|
@ -204,3 +205,7 @@ TORRENT_TEST(allow_fast_stress)
|
|||
, int(allowed_fast.size()), num_pieces - 1);
|
||||
TEST_CHECK(int(allowed_fast.size()) < num_pieces / 80);
|
||||
}
|
||||
#else
|
||||
TORRENT_TEST(dummy) {}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -66,6 +66,7 @@ TORRENT_TEST(seed_mode)
|
|||
});
|
||||
}
|
||||
|
||||
#ifndef TORRENT_DISABLE_LOGGING
|
||||
TORRENT_TEST(ip_notifier_setting)
|
||||
{
|
||||
int s_tick = 0;
|
||||
|
@ -114,6 +115,7 @@ TORRENT_TEST(ip_notifier_setting)
|
|||
|
||||
TEST_EQUAL(working_count, 2);
|
||||
}
|
||||
#endif
|
||||
|
||||
TORRENT_TEST(force_proxy)
|
||||
{
|
||||
|
|
|
@ -157,7 +157,8 @@ TORRENT_TEST(session_stats)
|
|||
});
|
||||
}
|
||||
|
||||
|
||||
// this test relies on picking up log alerts
|
||||
#ifndef TORRENT_DISABLE_LOGGING
|
||||
TORRENT_TEST(suggest)
|
||||
{
|
||||
int num_suggests = 0;
|
||||
|
@ -197,6 +198,7 @@ TORRENT_TEST(suggest)
|
|||
// time
|
||||
TEST_CHECK(num_suggests > 0);
|
||||
}
|
||||
#endif
|
||||
|
||||
TORRENT_TEST(utp_only)
|
||||
{
|
||||
|
|
|
@ -440,6 +440,7 @@ TORRENT_TEST(save_state_peer_id)
|
|||
TEST_CHECK(pid3[5] == 'r');
|
||||
}
|
||||
|
||||
#ifndef TORRENT_DISABLE_LOGGING
|
||||
TORRENT_TEST(init_dht)
|
||||
{
|
||||
auto count_dht_inits = [](session& ses)
|
||||
|
@ -577,3 +578,5 @@ TORRENT_TEST(reopen_network_sockets)
|
|||
|
||||
TEST_CHECK(count_alerts(s, 2, 0));
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -617,6 +617,7 @@ TORRENT_TEST(tracker_proxy)
|
|||
test_proxy(true);
|
||||
}
|
||||
|
||||
#ifndef TORRENT_DISABLE_LOGGING
|
||||
void test_stop_tracker_timeout(bool nostop)
|
||||
{
|
||||
// trick the min interval so that the stopped anounce is permitted immediately
|
||||
|
@ -705,3 +706,5 @@ TORRENT_TEST(stop_tracker_timeout)
|
|||
std::printf("\n\nexpect to NOT get a request with &event=stopped\n\n");
|
||||
test_stop_tracker_timeout(true);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue