salt icon indicating copy to clipboard operation
salt copied to clipboard

Fix file.directory clean=true with wildcard requisites

Open frebib opened this issue 2 years ago • 2 comments

States in the following form were not honouring the the requisite states that manage files when clean=true was applied. This fixes that by matching filenames using fnmatch, inspired by the original change that implemented wildcard requisites: a36b3d1858ad127bfe87b73c9faf737d7309bfb1

Signed-off-by: Joe Groocock [email protected]

Merge requirements satisfied?

[NOTICE] Bug fixes or features added to Salt require tests.

  • [ ] Docs
  • [x] Changelog - https://docs.saltproject.io/en/master/topics/development/changelog.html
  • [x] Tests written/updated

Commits signed with GPG?

Yes


The tests need more work. Ideally this would be implemented as a unit test, but I can't work out where is the correct place to put said tests. Any feedback/advice is welcome

frebib avatar Jul 07 '22 12:07 frebib

Tests seem to be working and passing locally now

frebib avatar Jul 07 '22 12:07 frebib

The added test seems to be failing on windows here.

MKLeb avatar Sep 19 '22 23:09 MKLeb

@frebib any luck with @MKLeb 's suggestion?

Ch3LL avatar Oct 13 '22 19:10 Ch3LL

This slipped through the cracks and I'm on PTO for another week. I'll try to remember to look at this when I'm back

frebib avatar Oct 13 '22 19:10 frebib

Closing this due to inactivity. Anyone should feel free to re-open it if they want to see it through to the end in one release cycle.

dwoz avatar Dec 10 '23 23:12 dwoz