MCPcopy Create free account
hub / github.com/bytecodealliance/rustix / test_abstract_unix_msg_unconnected

Function test_abstract_unix_msg_unconnected

tests/net/unix.rs:438–450  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

436#[cfg(linux_kernel)]
437#[test]
438fn test_abstract_unix_msg_unconnected() {
439 crate::init();
440
441 use std::os::unix::ffi::OsStrExt as _;
442
443 let tmpdir = tempfile::tempdir().unwrap();
444 let path = tmpdir.path().join("scp_4804");
445
446 let name = SocketAddrUnix::new_abstract_name(path.as_os_str().as_bytes()).unwrap();
447 assert_eq!(name.abstract_name(), Some(path.as_os_str().as_bytes()));
448 assert!(!name.is_unnamed());
449 do_test_unix_msg_unconnected(name);
450}
451
452#[cfg(not(any(target_os = "redox", target_os = "wasi")))]
453#[cfg(feature = "pipe")]

Callers

nothing calls this directly

Calls 4

initFunction · 0.70
pathMethod · 0.45
as_bytesMethod · 0.45

Tested by

no test coverage detected