MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_generate_ulid_shape

Function test_generate_ulid_shape

atomic-cli/src/commands/memory/new.rs:235–245  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

233
234 #[test]
235 fn test_generate_ulid_shape() {
236 let id = generate_ulid_lowercased();
237 assert_eq!(id.len(), 26, "ULID stem is 26 chars");
238 assert!(
239 id.chars()
240 .all(|c| c.is_ascii_lowercase() || c.is_ascii_digit()),
241 "ULID stem is lowercased Crockford base32: {id}"
242 );
243 // Two consecutive generations differ (randomness in the low bits).
244 assert_ne!(generate_ulid_lowercased(), generate_ulid_lowercased());
245 }
246
247 #[test]
248 fn test_new_writes_liftable_memory() {

Callers

nothing calls this directly

Calls 1

generate_ulid_lowercasedFunction · 0.85

Tested by

no test coverage detected