import Testing @testable import SprachmittlerCore /// T0.4: SP-2 allows short hashes in logs, never the underlying text. @Suite("Log redaction") struct LogRedactionTests { @Test func shortHashIsStableTwelveHexAndOpaque() { let hash = LogRedaction.shortHash("hello") #expect(hash == "2cf24dba5fb0") #expect(hash == LogRedaction.shortHash("hello")) #expect(hash.count == 12) #expect(hash.allSatisfy { $0.isHexDigit && !$0.isUppercase }) #expect(hash != LogRedaction.shortHash("hello!")) #expect(!hash.contains("hello")) } }