Ejemplo n.º 1
0
 /**
  * Test initiation for style type and paragraph style
  */
 public function testInitiation()
 {
     $object = new Font(htmlspecialchars('text', ENT_COMPAT, 'UTF-8'), array('alignment' => Jc::BOTH));
     $this->assertEquals(htmlspecialchars('text', ENT_COMPAT, 'UTF-8'), $object->getStyleType());
     $this->assertInstanceOf('PhpOffice\\PhpWord\\Style\\Paragraph', $object->getParagraphStyle());
     $this->assertTrue(is_array($object->getStyleValues()));
 }
Ejemplo n.º 2
0
 /**
  * Test initiation for style type and paragraph style
  */
 public function testInitiation()
 {
     $object = new Font('text', array('align' => 'both'));
     $this->assertEquals('text', $object->getStyleType());
     $this->assertInstanceOf('PhpOffice\\PhpWord\\Style\\Paragraph', $object->getParagraphStyle());
     $this->assertTrue(is_array($object->getStyleValues()));
 }