def METHOD_NAME(base_db, batch_db, base2_db):
    base_db[b"key-1"] = b"origin-1"
    base_db[b"key-2"] = b"origin-2"
    base2_db[b"key-1"] = b"origin-1"
    base2_db[b"key-2"] = b"origin-2"
    batch_db[b"key-1"] = b"value-1"
    del batch_db[b"key-2"]
    batch_db.commit_to(base2_db, apply_deletes=True)
    # after committing, length of pending changes should be 0
    assert len(batch_db.diff()) == 0
    # changes should be reflected in the target database, not the backing database
    assert base2_db[b"key-1"] == b"value-1"
    assert b"key-2" not in base2_db
    assert base_db[b"key-1"] == b"origin-1"
    assert base_db[b"key-2"] == b"origin-2"