chore: Remove unused API

pull/24376/head
Stuart Carnie 2023-05-05 16:15:22 +10:00
parent 2ba5fb4759
commit 455c78966c
No known key found for this signature in database
GPG Key ID: 848D9C9718D78B4F
1 changed files with 1 additions and 10 deletions

View File

@ -72,13 +72,6 @@ pub struct SelectStatement {
}
impl SelectStatement {
/// Return the `FILL` behaviour for the `SELECT` statement.
///
/// The default when no `FILL` clause present is `FILL(null)`.
pub fn fill(&self) -> FillClause {
self.fill.unwrap_or_default()
}
/// Return the sort order for the `SELECT` statement.
///
/// The default when no `ORDER BY` clause present is `TIME ASC`.
@ -760,8 +753,6 @@ mod test {
fn test_select_statement() {
let (_, got) = select_statement("SELECT value FROM foo").unwrap();
assert_eq!(got.to_string(), "SELECT value FROM foo");
// Assert default behaviour when `FILL` is omitted
assert_eq!(got.fill(), FillClause::Null);
let (_, got) =
select_statement(r#"SELECT f1,/f2/, f3 AS "a field" FROM foo WHERE host =~ /c1/"#)
@ -798,7 +789,7 @@ mod test {
got.to_string(),
r#"SELECT sum(value) FROM foo GROUP BY TIME(5m), host FILL(PREVIOUS)"#
);
assert_eq!(got.fill(), FillClause::Previous);
assert_matches!(got.fill, Some(FillClause::Previous));
let (_, got) = select_statement("SELECT value FROM foo ORDER BY DESC").unwrap();
assert_eq!(