// The media item has an empty source value, so the constraint validator
// should add a violation and return early before invoking the URL resolver.
$context = $this->prophesize(ExecutionContextInterface::class); $context->addViolation($constraint->invalidResourceMessage)->shouldBeCalled();