MCPcopy Create free account
hub / github.com/bootc-dev/bootc / test_kernel_lint

Function test_kernel_lint

crates/lib/src/lints.rs:1015–1029  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1013
1014 #[test]
1015 fn test_kernel_lint() -> Result<()> {
1016 let root = &fixture()?;
1017 let config = &LintExecutionConfig::default();
1018 // This one should pass
1019 check_kernel(root, config).unwrap().unwrap();
1020 root.create_dir_all("usr/lib/modules/5.7.2")?;
1021 root.write("usr/lib/modules/5.7.2/vmlinuz", "old vmlinuz")?;
1022 root.create_dir_all("usr/lib/modules/6.3.1")?;
1023 root.write("usr/lib/modules/6.3.1/vmlinuz", "new vmlinuz")?;
1024 assert!(check_kernel(root, config).is_err());
1025 root.remove_dir_all("usr/lib/modules/5.7.2")?;
1026 // Now we should pass again
1027 check_kernel(root, config).unwrap().unwrap();
1028 Ok(())
1029 }
1030
1031 #[test]
1032 fn test_kargs() -> Result<()> {

Callers

nothing calls this directly

Calls 2

check_kernelFunction · 0.85
fixtureFunction · 0.70

Tested by

no test coverage detected