Clear the warnings in test builds #218

Merged
jcoffey-dev merged 1 commits from chore/test-build-warnings into main 2026-10-28 02:44:15 +00:00
5 changed files with 8 additions and 4 deletions

No files matched your search

+2
View File
@@ -613,6 +613,8 @@ async fn insert_safe_defaults(bp: &mut Bootstrap) -> trc::Result<()> {
/// of never; spam training samples are kept 90 days instead of 180; Pyzor,
/// which sends a digest of each message's text to a public server, is off;
/// delivery history is kept 14 days instead of 30.
// Test builds leave out the caller (`cfg(not(feature = "test_mode"))`).
#[cfg_attr(feature = "test_mode", allow(dead_code))]
fn new_install_privacy_defaults(
security: &mut Security,
classifier: &mut SpamClassifier,
+1 -1
View File
@@ -39,7 +39,7 @@ struct Slot;
impl Slot {
fn take() -> Option<Slot> {
STREAMS
.fetch_update(Ordering::SeqCst, Ordering::SeqCst, |n| {
.try_update(Ordering::SeqCst, Ordering::SeqCst, |n| {
(n < MAX_STREAMS).then_some(n + 1)
})
.ok()
@@ -48,7 +48,9 @@ enum Event {
EvaluateAlerts,
// inbuxa: settings-reorg: probe the other nodes' ports
ProbePeerPorts,
// inbuxa: re-queue DKIM rotation and ACME renewal tasks a domain is missing
// inbuxa: re-queue DKIM rotation and ACME renewal tasks a domain is missing.
// Test builds never schedule it (`cfg(not(feature = "test_mode"))`).
#[cfg_attr(feature = "test_mode", allow(dead_code))]
CheckDomainTasks,
}
+1 -1
View File
@@ -153,7 +153,7 @@ fn refusal(response: &Value) -> String {
#[ignore]
#[tokio::test(flavor = "multi_thread")]
pub async fn front_ends_tests() {
let mut test = TestServerBuilder::new("front_ends_tests")
let test = TestServerBuilder::new("front_ends_tests")
.await
.with_default_listeners()
.await
+1 -1
View File
@@ -95,7 +95,7 @@ impl Account {
#[ignore]
#[tokio::test(flavor = "multi_thread")]
pub async fn sharing_policy_tests() {
let mut test = TestServerBuilder::new("sharing_policy_tests")
let test = TestServerBuilder::new("sharing_policy_tests")
.await
.with_default_listeners()
.await