Nelmio\Alice\Generator\Instantiator\Chainable\NoCallerMethodCallInstantiatorTest::testIgnoresConstructorMethodSpecifiedByTheFixtureIfIsSomethingElseThanTheConstructor PHP Method

testIgnoresConstructorMethodSpecifiedByTheFixtureIfIsSomethingElseThanTheConstructor() public method

Edge case allowed because this scenario should not occur. Indeed if the method is other than the constructor, the constructor is then a factory (static or not) i.e. has a caller. This situation is handled at the denormalization level.
    public function testIgnoresConstructorMethodSpecifiedByTheFixtureIfIsSomethingElseThanTheConstructor()
    {
        $fixture = new SimpleFixture('dummy', DummyWithRequiredParameterInConstructor::class, SpecificationBagFactory::create(new SimpleMethodCall('fake', [10])));
        $set = $this->instantiator->instantiate($fixture, ResolvedFixtureSetFactory::create(), new GenerationContext());
        $expected = new DummyWithRequiredParameterInConstructor(10);
        $actual = $set->getObjects()->get($fixture)->getInstance();
        $this->assertEquals($expected, $actual);
    }