@@ -227,7 +227,7 @@ pub async fn get_stats(
227
227
) -> Result < HttpResponse , StreamError > {
228
228
let stream_name = stream_name. into_inner ( ) ;
229
229
230
- if cfg ! ( not ( test ) ) && !PARSEABLE . streams . contains ( & stream_name) {
230
+ if !PARSEABLE . streams . contains ( & stream_name) {
231
231
// For query mode, if the stream not found in memory map,
232
232
//check if it exists in the storage
233
233
//create stream and schema from storage
@@ -634,27 +634,6 @@ mod tests {
634
634
635
635
use crate :: handlers:: http:: modal:: utils:: logstream_utils:: PutStreamHeaders ;
636
636
637
- // TODO: Fix this test with routes
638
- // #[actix_web::test]
639
- // #[should_panic]
640
- // async fn get_stats_panics_without_logstream() {
641
- // let req = TestRequest::default().to_http_request();
642
- // let _ = get_stats(req).await;
643
- // }
644
-
645
- // #[actix_web::test]
646
- // async fn get_stats_stream_not_found_error_for_unknown_logstream() -> anyhow::Result<()> {
647
- // match get_stats(
648
- // web::Path::from("test".to_string()),
649
- // Query(StatsParams { date: None }),
650
- // )
651
- // .await
652
- // {
653
- // Err(StreamError::StreamNotFound(_)) => Ok(()),
654
- // _ => bail!("expected StreamNotFound error"),
655
- // }
656
- // }
657
-
658
637
#[ actix_web:: test]
659
638
async fn header_without_log_source ( ) {
660
639
let req = TestRequest :: default ( ) . to_http_request ( ) ;
0 commit comments