override prophecy creation

@return ObjectProphecy
175445
private function createCommandProphecy()
    {
        $prophet = new Prophet;
        $prophecy = $prophet->prophesize()->willImplement(InlineConfigCommandInterface::class);
        $prophecy
            ->setName('foo')
            ->shouldBeCalled();
        $prophecy
            ->getConfig()
            ->willReturn(['name'=>'foo']);

        return $prophecy;
    }
766870
public function setPreferNone()
    {
        //====================================================================//
        // Safety Checks ==> Verify a new Field Exists
        if (empty($this->new)) {
            Splash::log()->err("ErrFieldsNoNew");
        } else {
            //====================================================================//
            // Update New Field structure
            $this->new->syncmode = self::MODE_NONE;
        }

        return $this;
    }
455774
public function build(): SetLifecycleEventsEnabledRequest
	{
		$instance = new SetLifecycleEventsEnabledRequest();
		if ($this->enabled === null) {
			throw new BuilderException('Property [enabled] is required.');
		}
		$instance->enabled = $this->enabled;
		return $instance;
	}
747943
public function finalize(): self
    {
        if (!$this->isFinalized) {
            $this->normalizeDefinition();
            $this->isFinalized = true;
            $this->definition = new MockDefinition(
                $this->types,
                $this->customMethods,
                $this->customProperties,
                $this->customStaticMethods,
                $this->customStaticProperties,
                $this->customConstants,
                $this->className
            );
        }

        return $this;
    }
33827
public static function instance(): self
    {
        if (!self::$instance) {
            self::$instance = new self(
                Sequencer::sequence('spy-label'),
                CallFactory::instance(),
                Invoker::instance(),
                GeneratorSpyFactory::instance(),
                IterableSpyFactory::instance()
            );
        }

        return self::$instance;
    }
1118434
public function build(): SetScriptExecutionDisabledRequest
	{
		$instance = new SetScriptExecutionDisabledRequest();
		if ($this->value === null) {
			throw new BuilderException('Property [value] is required.');
		}
		$instance->value = $this->value;
		return $instance;
	}
1209594
public function createNew()
    {
        $resource = $this->traitCreateNew();

        if (!$resource instanceof TranslatableInterface) {
            throw new \InvalidArgumentException('Resource must implement TranslatableInterface.');
        }

        $resource->setCurrentLocale($this->localeProvider->getCurrentLocale());
        $resource->setFallbackLocale($this->localeProvider->getFallbackLocale());

        return $resource;
    }
435035
protected function getForeignAttributesForCreate()
	{
		$foreign = array($this->getPlainForeignKey() => $this->getParentKey());

		$foreign[last(explode('.', $this->morphType))] = $this->morphClass;

		return $foreign;
	}
874269
protected function createNewObject()
    {
        $jwkset = new JWKSet();
        for ($i = 0; $i < $this->nb_keys; ++$i) {
            $key = $this->createJWK();
            $jwkset->addKey($key);
        }

        return $jwkset;
    }
503040
public function build()
    {
        if ($this->getContext()) {
            $context = $this->getContext();
        } else {
            $context = new Object2ArrayContext();
        }

        $this->prepareContext($context);

        return new Object2Array($context);
    }
537106
public function create(): self
    {
        $this->payload = null;
        $this->isPayloadDetached = false;
        $this->signatures = [];
        $this->isPayloadEncoded = null;

        return $this;
    }
1075454
public function build(): GetFileInfoRequest
	{
		$instance = new GetFileInfoRequest();
		if ($this->objectId === null) {
			throw new BuilderException('Property [objectId] is required.');
		}
		$instance->objectId = $this->objectId;
		return $instance;
	}
105985
public function build(): ExposeDevToolsProtocolRequest
	{
		$instance = new ExposeDevToolsProtocolRequest();
		if ($this->targetId === null) {
			throw new BuilderException('Property [targetId] is required.');
		}
		$instance->targetId = $this->targetId;
		$instance->bindingName = $this->bindingName;
		return $instance;
	}
244211
public function build(): AddScriptToEvaluateOnNewDocumentRequest
	{
		$instance = new AddScriptToEvaluateOnNewDocumentRequest();
		if ($this->source === null) {
			throw new BuilderException('Property [source] is required.');
		}
		$instance->source = $this->source;
		$instance->worldName = $this->worldName;
		return $instance;
	}
163359
protected function _buildPayload()
    {
        $this->_payload->setOrderType(static::ORDER_TYPE)
            ->setCustomerOrderId($this->_order->getIncrementId())
            ->setReasonCode($this->_getReasonCode())
            ->setReason($this->_getReasonDescription());
        return $this;
    }
1222171
protected function createWidget()
    {
        $type   = $this->widgetData('type');
        $widget = $this->resolveWidget($type);

        if ($this instanceof ObjectContainerInterface && $widget instanceof ObjectContainerInterface) {
            if (empty($widget->objType())) {
                $widget->setObjType($this->objType());
            }

            if (empty($widget->objId()) && !empty($this->objId())) {
                $widget->setObjId($this->objId());
            }
        }

        $widget->setData($this->widgetData());
        $widget->setData($this->renderableData());

        return $widget;
    }
694709
public function build(): object
    {
        $object = $this->instanciator->build($this->class, $this->properties);
        $parameters = $this->instanciator->parameters($this->class);

        //avoid injecting the properties already used in the constructor
        $properties = $this
            ->properties
            ->filter(function(string $property) use ($parameters) {
                return !$parameters->contains($property);
            });
        $refl = new ReflectionObject(
            $object,
            $properties,
            $this->injectionStrategy
        );

        return $refl->build();
    }