Example #1
0
 function test_creacion_archivo_y_generacion_clase()
 {
     $this->hijo = "hijo_vacio";
     $this->padre = "padre_hijo_vacio";
     //Se crea el archivo del hijo
     $archivo = new toba_archivo_php($this->path_hijo());
     $archivo->crear_basico();
     //Se genera la subclase
     $padre = new toba_archivo_php($this->path_padre());
     $clase = new toba_clase_php($this->hijo, $archivo, $this->padre, $this->path_padre());
     $clase->set_meta_clase(new info_componente(array()));
     $clase->generar($this->generar_todo());
     //Se incluyen y se verifica que funcionan correctamente
     $padre->incluir();
     $archivo->incluir();
     $clase = new ReflectionClass($this->hijo);
     $this->AssertEqual($this->hijo, $clase->getName());
 }