copy before assert (per @alex-hofsteede)