DAV server passing Litmus test suite

This commit is contained in:
mdecimus
2025-03-26 17:56:14 +01:00
parent 8004e32870
commit 3f825aaafd
367 changed files with 2026 additions and 1468 deletions

View File

@@ -12,9 +12,9 @@ use trc::EvalEvent;
use crate::Server;
use super::{
functions::{ResolveVariable, FUNCTIONS},
if_block::IfBlock,
BinaryOperator, Constant, Expression, ExpressionItem, Setting, UnaryOperator, Variable,
functions::{FUNCTIONS, ResolveVariable},
if_block::IfBlock,
};
impl Server {

View File

@@ -4,11 +4,11 @@
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-SEL
*/
use std::{cmp::Ordering, net::IpAddr, vec::IntoIter};
use std::{cmp::Ordering, net::IpAddr, vec::IntoIter};
use directory::backend::RcptType;
use mail_auth::IpLookupStrategy;
use store::{dispatch::lookup::KeyValue, Deserialize, Rows, Value};
use store::{Deserialize, Rows, Value, dispatch::lookup::KeyValue};
use trc::AddContext;
use crate::Server;

View File

@@ -55,9 +55,5 @@ pub(crate) fn fn_if_then(v: Vec<Variable>) -> Variable {
let iff = v.next().unwrap();
let then = v.next().unwrap();
if condition.to_bool() {
iff
} else {
then
}
if condition.to_bool() { iff } else { then }
}

View File

@@ -4,14 +4,14 @@
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-SEL
*/
use utils::config::{utils::AsKey, Config};
use utils::config::{Config, utils::AsKey};
use crate::expr::{Constant, Expression};
use super::{
ConstantValue, ExpressionItem,
parser::ExpressionParser,
tokenizer::{TokenMap, Tokenizer},
ConstantValue, ExpressionItem,
};
#[derive(Debug, Clone, PartialEq, Eq)]

View File

@@ -69,7 +69,7 @@ pub const VARIABLES_MAP: &[(&str, u32)] = &[
];
use regex::Regex;
use utils::config::{utils::ParseValue, Rate};
use utils::config::{Rate, utils::ParseValue};
use self::tokenizer::TokenMap;

View File

@@ -4,7 +4,7 @@
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-SEL
*/
use super::{tokenizer::Tokenizer, BinaryOperator, Expression, ExpressionItem, Token};
use super::{BinaryOperator, Expression, ExpressionItem, Token, tokenizer::Tokenizer};
pub struct ExpressionParser<'x> {
pub(crate) tokenizer: Tokenizer<'x>,