mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-07-02 21:02:34 +00:00
fix(tests): copy actual screens to recorded when accepting UI diff
This commit is contained in:
parent
6b7ee55868
commit
84b9f703b4
@ -226,6 +226,12 @@ def update_fixtures_with_diff() -> int:
|
|||||||
diff = json.loads(line)
|
diff = json.loads(line)
|
||||||
FILE_HASHES[diff["test_name"]] = diff["actual_hash"]
|
FILE_HASHES[diff["test_name"]] = diff["actual_hash"]
|
||||||
|
|
||||||
|
# Copying the recorded screens to "recorded" dir
|
||||||
|
actual = SCREENS_DIR / diff["test_name"] / "actual"
|
||||||
|
recorded = SCREENS_DIR / diff["test_name"] / "recorded"
|
||||||
|
shutil.rmtree(recorded, ignore_errors=True)
|
||||||
|
shutil.copytree(actual, recorded)
|
||||||
|
|
||||||
write_fixtures(remove_missing=False)
|
write_fixtures(remove_missing=False)
|
||||||
|
|
||||||
# Returning the amount of updated hashes
|
# Returning the amount of updated hashes
|
||||||
|
Loading…
Reference in New Issue
Block a user