def METHOD_NAME(remove_missing: bool = False) -> int:
    """Update the fixtures.json file with the actual hashes from the latest run.
    Used in --ui=record and in update_fixtures.py
    """
    results = list(TestResult.recent_results())
    for result in results:
        result.store_recorded()
    common.write_fixtures_complete(results, remove_missing=remove_missing)
    return len(results)