Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
Signed-off-by: Devan <[email protected]>
  • Loading branch information
devanbenz committed Aug 3, 2024
1 parent 758dd53 commit fe2ec75
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions tests/time_bucket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ async fn test_time_bucket_minutes(mut conn: PgConnection, tempdir: TempDir) -> R

assert_eq!(10, data.len());


let data: Vec<(NaiveDateTime,)> = "SELECT time_bucket(INTERVAL '1 MINUTE', timestamp::TIMESTAMP, INTERVAL '5 MINUTE') AS bucket, AVG(value) as avg_value FROM timeseries GROUP BY bucket ORDER BY bucket;"
.fetch_result(&mut conn).unwrap();

Expand All @@ -87,7 +86,6 @@ async fn test_time_bucket_minutes(mut conn: PgConnection, tempdir: TempDir) -> R
Ok(())
}


#[rstest]
async fn test_time_bucket_years(mut conn: PgConnection, tempdir: TempDir) -> Result<()> {
let stored_batch = time_series_record_batch_years()?;
Expand All @@ -105,7 +103,7 @@ async fn test_time_bucket_years(mut conn: PgConnection, tempdir: TempDir) -> Res
"CREATE FOREIGN TABLE timeseries () SERVER parquet_server OPTIONS (files '{}')",
parquet_path.to_str().unwrap()
)
.execute(&mut conn);
.execute(&mut conn);

#[allow(clippy::single_match)]
match "SELECT time_bucket(INTERVAL '2 DAY', timestamp::DATE) AS bucket, AVG(value) as avg_value FROM timeseries GROUP BY bucket ORDER BY bucket;".execute_result(&mut conn) {
Expand Down Expand Up @@ -133,7 +131,6 @@ async fn test_time_bucket_years(mut conn: PgConnection, tempdir: TempDir) -> Res

assert_eq!(10, data.len());


let data: Vec<(Date,)> = "SELECT time_bucket(INTERVAL '5 YEAR', timestamp::DATE) AS bucket, AVG(value) as avg_value FROM timeseries GROUP BY bucket ORDER BY bucket;"
.fetch_result(&mut conn).unwrap();

Expand Down

0 comments on commit fe2ec75

Please sign in to comment.