getUserManager(); $userRepo = $this->getUserRepository(); $user = new User(); $user->setEmail(ByteString::fromRandom(6)->toString().'@example.com'); $user->setPhoneNumber('+33600000000'); $user->setPassword('foo'); $userManager->save($user, true); $count = $userRepo->count([]); self::assertSame(self::COUNT + 1, $count); $userManager->remove($user, true); $count = $userRepo->count([]); self::assertSame(self::COUNT, $count); } }