MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / test_validate_bdf_invalid

Function test_validate_bdf_invalid

crates/openshell-vfio/src/sysfs.rs:241–248  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

239
240 #[test]
241 fn test_validate_bdf_invalid() {
242 assert!(validate_bdf("").is_err());
243 assert!(validate_bdf("0000:2d:00").is_err());
244 assert!(validate_bdf("0000:2d:00.00").is_err());
245 assert!(validate_bdf("000g:2d:00.0").is_err());
246 assert!(validate_bdf("0000-2d-00.0").is_err());
247 assert!(validate_bdf("0000:2d:00:0").is_err());
248 }
249
250 #[test]
251 fn test_validate_bdf_rejects_metacharacters() {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected