Files
nielashandASRodrigo1 ff0704b7e2 bisync: add tests for skipping the check for identical files
- TestCheckConflictsSkipsCheck: the check for identical files is skipped
  with --size-only, and with --ignore-checksum only when the paths have no
  hash in common.
- test_equal_skipped: an identical file that is new on both paths with
  --ignore-checksum is recorded, so deleting it on Path1 deletes it on
  Path2. Adds the "ignore-checksum" scenario argument.
- test_conflict_window: Path1 changes between the listing snapshot and
  the check for identical files.

Co-Authored-By: ASRodrigo1 <45823308+asrodrigo1@users.noreply.github.com>
2026-10-14 12:00:45 +01:00

58 lines
2.3 KiB
Plaintext

test conflict window
# Check identical files when the paths change between the listing snapshot and the check for identical files
# - Path2 becomes identical to Path1 before the check, with a newer modtime file1 (file1A, file1B)
# - Both paths change identically before the check on two runs in a row, then stop file2 (file2A, file2B, file2C)
# - Path1 becomes identical to Path2 before the check, with a newer modtime file3 (file3A, file3B)
test initial bisync
bisync resync
test new on both paths, same size and modtime, different content - file1 (file1A, file1B)
touch-glob 2001-01-02 {datadir/} file1*.txt
copy-as {datadir/}file1A.txt {path1/} file1.txt
copy-as {datadir/}file1B.txt {path2/} file1.txt
test bisync with Path2 becoming identical to Path1 before the check, with a newer modtime
touch-glob 2001-03-04 {datadir/} file1A.txt
hook before-check copy-as {datadir/}file1A.txt {path2/} file1.txt
bisync
test bisync after file1 changed before the check
bisync
test recover with --resync if the previous runs failed
bisync resync
test new on both paths and identical - file2 (file2A)
touch-glob 2002-01-02 {datadir/} file2A.txt
copy-as {datadir/}file2A.txt {path1/} file2.txt
copy-as {datadir/}file2A.txt {path2/} file2.txt
test bisync with both paths changing file2 identically before the check
touch-glob 2002-03-04 {datadir/} file2B.txt
hook before-check copy-as {datadir/}file2B.txt {path1/} file2.txt
hook before-check copy-as {datadir/}file2B.txt {path2/} file2.txt
bisync
test bisync with both paths changing file2 identically before the check again
touch-glob 2002-05-06 {datadir/} file2C.txt
hook before-check copy-as {datadir/}file2C.txt {path1/} file2.txt
hook before-check copy-as {datadir/}file2C.txt {path2/} file2.txt
bisync
test bisync after file2 stops changing
bisync
test changed on both paths, same size and modtime, different content - file3 (file3A, file3B)
touch-glob 2003-01-02 {datadir/} file3*.txt
copy-as {datadir/}file3A.txt {path1/} file3.txt
copy-as {datadir/}file3B.txt {path2/} file3.txt
test bisync with Path1 becoming identical to Path2 before the check, with a newer modtime
touch-glob 2003-03-04 {datadir/} file3B.txt
hook before-check copy-as {datadir/}file3B.txt {path1/} file3.txt
bisync
test bisync after file3 changed before the check
bisync