test: Use insta, closes #57
Use insta for UI tests, adds snapshots of UI layout
This commit is contained in:
@@ -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
@@ -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
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user