def check_installed_files(self):
mismatches = []<EOL>record_path = os.path.join(self.path, '<STR_LIT>')<EOL>if os.path.exists(record_path):<EOL><INDENT>for path, _, _ in self.list_installed_files():<EOL><INDENT>if path == record_path:<EOL><INDENT>continue<EOL><DEDENT>if not os.path.exists(path):<EOL><INDENT>mismatches.append((path, '<STR_LIT>', True, False))<EOL><DEDENT><DEDENT><DEDENT>return mismatches<EOL>
Checks that the hashes and sizes of the files in ``RECORD`` are
matched by the files themselves. Returns a (possibly empty) list of
mismatches. Each entry in the mismatch list will be a tuple consisting
of the path, 'exists', 'size' or 'hash' according to what didn't match
(existence is checked first, then size, then hash), the expected
value and the actual value.