feat: Add tests for remove command

This commit is contained in:
Cristian 2020-08-21 13:32:31 -05:00 committed by Cristian Vargas
parent a8ed72501d
commit fe9604a772
4 changed files with 68 additions and 8 deletions
archivebox/index

View file

@ -24,7 +24,6 @@ def parse_sql_main_index(out_dir: str=OUTPUT_DIR) -> Iterator[Link]:
@enforce_types
def remove_from_sql_main_index(snapshots: QuerySet, out_dir: str=OUTPUT_DIR) -> None:
setup_django(out_dir, check_db=True)
from core.models import Snapshot
from django.db import transaction
with transaction.atomic():