From c197766229a67b179622a3f7c5c9aea3d4d9fc06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20M=C3=BCller?= Date: Fri, 26 Jun 2026 15:38:49 +0200 Subject: [PATCH] Fix formatting --- src/testing/bfs_testing.rs | 3 ++- src/testing/dfs_testing.rs | 8 ++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/testing/bfs_testing.rs b/src/testing/bfs_testing.rs index 7d49f92..532d289 100644 --- a/src/testing/bfs_testing.rs +++ b/src/testing/bfs_testing.rs @@ -187,7 +187,8 @@ macro_rules! bfs_tests { assert!( found == vertices[7] || found == vertices[8], "unexpected nearest match vertex {found:?}, should be {:?} or {:?}", - vertices[7], vertices[8] + vertices[7], + vertices[8] ); } diff --git a/src/testing/dfs_testing.rs b/src/testing/dfs_testing.rs index 255445d..205f020 100644 --- a/src/testing/dfs_testing.rs +++ b/src/testing/dfs_testing.rs @@ -157,7 +157,8 @@ macro_rules! dfs_tests { assert_eq!( $crate::algorithms::dfs_find_where(&graph, vertices[0], |v| v == vertices[9]), Some(vertices[9]), - "expected to find connected vertex"); + "expected to find connected vertex" + ); } fn assert_dfs_visited( @@ -190,7 +191,10 @@ macro_rules! dfs_tests { for i in 1..10 { let v = vertices[i]; let p = predecessors[v].expect(&format!("vertex {v:?} should have a predecessor")); - assert!(visited[p], "predecessor {p:?} of vertex {v:?} should be visited"); + assert!( + visited[p], + "predecessor {p:?} of vertex {v:?} should be visited" + ); assert!( graph.are_adjacent(v, p), "predecessor {p:?} of vertex {v:?} should be adjacent"