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

Function test_detect_encoding_utf8

atomic-core/src/record/workflow/compare.rs:507–514  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

505
506 #[test]
507 fn test_detect_encoding_utf8() {
508 assert_eq!(detect_encoding(b"Hello, World!"), Encoding::Utf8);
509 assert_eq!(detect_encoding(b""), Encoding::Utf8);
510 assert_eq!(
511 detect_encoding("UTF-8 with émojis 🎉".as_bytes()),
512 Encoding::Utf8
513 );
514 }
515
516 #[test]
517 fn test_detect_encoding_binary_null() {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected