Description
I was very thankful when I noticed that a standard-ish way to validate the contents of a tar file was available:
rules_pkg/pkg/verify_archive.bzl
Line 15 in 6c2e325
"""Rule to test that the content of an archive has particular properties.
This is available for integration testing, when people want to verify that all
the files they expect are in an archive. Or possibly, they want to verify that
some files do not appear.The execution time is O(# expected patterns * size of archive).
"""
Unfortunately, I don't think it's usable (it's possible that external re-use of this test capability might not be the intended audience)
- template at
rules_pkg/pkg/verify_archive.bzl
Line 80 in 6c2e325
//pkg:...
not@rules_pkg//pkg:...
so it cannot be reached in a dependent project trying to useverify_archive_test
- template at item 1 is not included in the rules_pkg-0.9.1 archive
- test lib at
rules_pkg/pkg/verify_archive.bzl
Line 125 in 6c2e325
dev = [ "//pkg:...
not@rules_pkg//pkg:...
with similar barrier to point 1.
Tentatively resolved
Points 1 and 3 are easily resolved; for point 2, I'm not certain how the missing file should be added to the delivered tar file in the release.