The row the test writes survives the backup/restore cycle (plugin tables aren't in the export), so on the second run the GET returned 1 and the "starts at 0" assertion blew up. Explicitly reset the flag at the start, then flip, then reset again — each run lands the DB in the same state it started. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>