Esempio n. 1
0
 /**
  * @test
  * it should allow not specifying the class of simple objects
  */
 public function it_should_allow_not_specifying_the_class_of_simple_objects()
 {
     // not specifying a ctor method for tad_Dependency
     // $this->sut->setCtor( 'dependency', 'DependencyObjectOne' );
     $this->sut->setVar('string', 'foo');
     $this->sut->setVar('int', 23);
     $class = 'DependingClassThree';
     $dependencyClass = 'ConcreteClassOne';
     $this->sut->setCtor('object', $class, '~' . $dependencyClass);
     $i = $this->sut->make('object');
     $this->assertInstanceOf($class, $i);
     $this->assertInstanceOf($dependencyClass, $i->classOne);
 }