test: Use insta, closes #57

Use insta for UI tests, adds snapshots of UI layout
This commit is contained in:
Jack Wills
2025-04-16 11:16:45 +00:00
parent 8f959c5408
commit 9362d7b481
126 changed files with 2059 additions and 1773 deletions
+2 -1
View File
@@ -35,7 +35,8 @@ impl ContainerId {
}
/// Only return first 8 chars of id, is usually more than enough for uniqueness
/// TODO container id is a hex string, so can assume that 0..=8 will always return a 8 char ascii &str - need to update tests to use real ids, or atleast strings of the correct-ish length
/// TODO container id is a hex string, so can assume that 0..=8 will always return a 8 char ascii &str
/// need to update tests to use real ids, or atleast strings of the correct-ish length
pub fn get_short(&self) -> String {
self.0.chars().take(8).collect::<String>()
}
+2 -2
View File
@@ -420,8 +420,8 @@ impl AppData {
}
/// Get all the ContainerItems
/// Thnk this allow block can be removed with the 1.87 release of Clippy
#[allow(clippy::missing_const_for_fn)]
/// Thnk this allow block can be removed with the 1.87 release of Clippy
#[allow(clippy::missing_const_for_fn)]
pub fn get_container_items(&self) -> &[ContainerItem] {
&self.containers.items
}