Skip to content

Commit

Permalink
CI: also install attr in one of the CI job to test a cp feature
Browse files Browse the repository at this point in the history
  • Loading branch information
sylvestre committed Jan 4, 2025
1 parent 361f166 commit 8036f94
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/CICD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,11 @@ jobs:
# * ensure '.clippy.toml' MSRV configuration setting is equal to ${{ env.RUST_MIN_SRV }}
CLIPPY_MSRV=$(grep -P "(?i)^\s*msrv\s*=\s*" .clippy.toml | grep -oP "\d+([.]\d+)+")
if [ "${CLIPPY_MSRV}" != "${{ env.RUST_MIN_SRV }}" ]; then { echo "::error file=.clippy.toml::Incorrect MSRV configuration for clippy (found '${CLIPPY_MSRV}'; should be '${{ env.RUST_MIN_SRV }}'); update '.clippy.toml' with 'msrv = \"${{ env.RUST_MIN_SRV }}\"'" ; exit 1 ; } ; fi
- name: Install/setup prerequisites
shell: bash
run: |
# Install a package for one of the tests
sudo apt-get -y update ; sudo apt-get -y install attr
- name: Info
shell: bash
run: |
Expand Down
8 changes: 4 additions & 4 deletions tests/by-util/test_cp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5939,13 +5939,12 @@ fn test_cp_preserve_xattr_readonly_source() {
at.touch(source_file);

let xattr_key = "user.test";
let xattr_value = "value";
match Command::new("setfattr")
.args([
"-n",
xattr_key,
"-v",
xattr_value,
"value",
&at.plus_as_string(source_file),
])
.status()
Expand Down Expand Up @@ -5975,8 +5974,9 @@ fn test_cp_preserve_xattr_readonly_source() {

let stdout = String::from_utf8_lossy(&getfattr_output.stdout);
assert!(
stdout.contains("user.test"),
"Expected 'user.test' not found in getfattr output:\n{}",
stdout.contains(xattr_key),
"Expected '{}' not found in getfattr output:\n{}",
xattr_key,
stdout
);

Expand Down

0 comments on commit 8036f94

Please sign in to comment.