ostreedev / ostree-rs-ext

Rust library with higher level APIs on top of the core ostree API
Apache License 2.0
72 stars 22 forks source link

tests: two fixes #637

Closed cgwalters closed 1 month ago

cgwalters commented 1 month ago

fixture: Add missing trailing NUL in security.selinux xattr

Because we were only doing bare-user checkouts in the test suite (and not trying to physically materialize the xattrs) and because ostree today doesn't validate xattrs, this problem was silently ignored. But I was looking at changing the tests to do a checkout, and this caused confusing failures.

Add the missing trailing NUL. Also while we're here, split the xattr function in two; one which returns the Rust-native value and a wrapper which converts to GVariant.

This will be useful later.


tests: Add some error context

This helped me debug a recent problem.