-
Notifications
You must be signed in to change notification settings - Fork 217
Closed
Labels
P1An issue that must be resolved. Must have an assigneeAn issue that must be resolved. Must have an assigneefeature-request
Description
The intent is that consumers of the rules should have a tool that facilitates writing non-brittle tests to validate they set things up the right way. I have seen many cases of people writing test that do things like bit compares to golden files. These breaks too often. Off the cuff concept model.
validate_archive_test(
name = "my_test",
target = ":foo.zip", # or tar. The rule should take either. Maybe .deb, rpm too.
# must contain everything here, in any order, and can contain more
contains = [
"usr/local/sbin/abld",
"usr/local/sbin/web_server",
".*/foo/bar.*.exe", # yes, these are regexes.
],
does_not_contain_regex = [ # none of these regexes must match any file
".*/MANIFEST",
],
has_entries = ">=3",
require_entries_sorted = True, # But what does sorted mean? What locale?
)
This may be a matter of improving our current test utilities and externalizing them.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
P1An issue that must be resolved. Must have an assigneeAn issue that must be resolved. Must have an assigneefeature-request