FileSubject¶
FileSubject.basename¶
FileSubject.basename()
Returns a StrSubject asserting on the files basename value.
Method: FileSubject.basename
- RETURNS ¶
StrSubjectobject.
FileSubject.equals¶
FileSubject.equals(expected)
Asserts that expected references the same file as self.
This uses Bazel’s notion of File equality, which usually includes
the configuration, owning action, internal hash, etc of a File. The
particulars of comparison depend on the actual Java type implementing
the File object (some ignore owner, for example).
NOTE: This does not compare file content. Starlark cannot read files.
NOTE: Same files generated by different owners are likely considered
not equal to each other. The alternative for this is to assert the
File.path paths are equal using [FileSubject.path()]
Method: FileSubject.equals
PARAMETERS ¶
- expected¶:
undocumented
FileSubject.new¶
Creates a FileSubject asserting against the given file.
Method: FileSubject.new
PARAMETERS ¶
- RETURNS ¶
FileSubjectobject.
FileSubject.path¶
FileSubject.path()
Returns a StrSubject asserting on the files path value.
Method: FileSubject.path
- RETURNS ¶
StrSubjectobject.
FileSubject.short_path_equals¶
FileSubject.short_path_equals(path)
Asserts the file’s short path is equal to the given path.
Method: FileSubject.short_path_equals
PARAMETERS ¶