bindiff_test

load("@tools_ocaml//rules:bindiff_test.bzl", "bindiff_test")

bindiff_test(name, file1, file2, failure_message, kwargs)

A macro that generates a rule that compares two binary files.

The rule uses shell command cmp on Linux/macOS/non-Windows, and a cmd.exe command (fc.exe) on Windows (no Bash is required).

Derived from skylib diff_test.

The test succeeds if the files' contents match.

PARAMETERS

Name Description Mandatory Default Value

name

The name of the test rule.

Yes

file1

Label of the file to compare to file2.

Yes

file2

Label of the file to compare to file1.

Yes

failure_message

Additional message to log if the files' contents do not match.

No

None

kwargs

The common attributes for tests.

No