Skip to content

Commit 5f63301

Browse files
committed
Fix: Code convention
1 parent 8f85515 commit 5f63301

File tree

4 files changed

+9
-20
lines changed

4 files changed

+9
-20
lines changed

src/PhpWord/Writer/ePub3.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ public function save(string $filename): void
8181
if (!$part instanceof AbstractPart) {
8282
continue;
8383
}
84-
8584

8685
$zip->addFromString($fileName, $part->write());
8786
}
@@ -90,4 +89,4 @@ public function save(string $filename): void
9089
$zip->close();
9190
$this->cleanupTempFile();
9291
}
93-
}
92+
}

src/PhpWord/Writer/ePub3/Part/AbstractPart.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ abstract class AbstractPart
3434
/**
3535
* Set parent writer.
3636
*
37-
* @param \PhpOffice\PhpWord\Writer\AbstractWriter $writer
38-
*
3937
* @return self
4038
*/
4139
public function setParentWriter(AbstractWriter $writer)

src/PhpWord/Writer/ePub3/Style/AbstractStyle.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ abstract class AbstractStyle
3434
/**
3535
* Set parent writer.
3636
*
37-
* @param \PhpOffice\PhpWord\Writer\AbstractWriter $writer
38-
*
3937
* @return self
4038
*/
4139
public function setParentWriter(AbstractWriter $writer)

tests/PhpWordTests/Writer/ePub3Test.php

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,21 +22,19 @@
2222
use PhpOffice\PhpWord\Writer\ePub3;
2323

2424
/**
25-
* Test class for PhpOffice\PhpWord\Writer\Epub3
25+
* Test class for PhpOffice\PhpWord\Writer\Epub3.
2626
*
2727
* @runTestsInSeparateProcesses
2828
*/
2929
class ePub3Test extends \PHPUnit\Framework\TestCase
3030
{
3131
/**
32-
* Test document construction
32+
* Test document construction.
3333
*/
3434
public function testConstruct(): void
3535
{
3636
$object = new ePub3(new PhpWord());
37-
3837
self::assertInstanceOf(PhpWord::class, $object->getPhpWord());
39-
4038
self::assertEquals('./', $object->getDiskCachingDirectory());
4139
foreach (['Content', 'Manifest', 'Mimetype'] as $part) {
4240
self::assertInstanceOf(
@@ -51,7 +49,7 @@ public function testConstruct(): void
5149
}
5250

5351
/**
54-
* Test construction with null
52+
* Test construction with null.
5553
*/
5654
public function testConstructWithNull(): void
5755
{
@@ -62,7 +60,7 @@ public function testConstructWithNull(): void
6260
}
6361

6462
/**
65-
* Test saving document
63+
* Test saving document.
6664
*/
6765
public function testSave(): void
6866
{
@@ -78,24 +76,20 @@ public function testSave(): void
7876
$section->addTitle('Test', 1);
7977
$section->addPageBreak();
8078
$section->addImage($imageSrc);
81-
8279
$writer = new ePub3($phpWord);
8380
$writer->save($file);
84-
8581
self::assertFileExists($file);
86-
8782
unlink($file);
8883
}
8984

9085
/**
91-
* Test PHP output
86+
* Test PHP output.
9287
*/
9388
public function testSavePhpOutput(): void
9489
{
9590
$phpWord = new PhpWord();
9691
$section = $phpWord->addSection();
9792
$section->addText('Test');
98-
9993
$writer = new ePub3($phpWord);
10094
ob_start();
10195
$writer->save('php://output');
@@ -105,7 +99,7 @@ public function testSavePhpOutput(): void
10599
}
106100

107101
/**
108-
* Test disk caching
102+
* Test disk caching.
109103
*/
110104
public function testSetGetUseDiskCaching(): void
111105
{
@@ -116,7 +110,7 @@ public function testSetGetUseDiskCaching(): void
116110
}
117111

118112
/**
119-
* Test disk caching exception
113+
* Test disk caching exception.
120114
*/
121115
public function testSetUseDiskCachingException(): void
122116
{
@@ -126,4 +120,4 @@ public function testSetUseDiskCachingException(): void
126120
$object = new ePub3();
127121
$object->setUseDiskCaching(true, $dir);
128122
}
129-
}
123+
}

0 commit comments

Comments
 (0)