File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -252,7 +252,7 @@ public function testSetImageValue()
252
252
$ testFileName = 'images-test-sample.docx ' ;
253
253
$ phpWord = new \PhpOffice \PhpWord \PhpWord ();
254
254
$ section = $ phpWord ->addSection ();
255
- $ section ->addText ('${Test} --- ${Test } ' );
255
+ $ section ->addText ('${Test:width=100:ratio=true } ' );
256
256
$ objWriter = \PhpOffice \PhpWord \IOFactory::createWriter ($ phpWord , 'Word2007 ' );
257
257
$ objWriter ->save ($ testFileName );
258
258
$ this ->assertFileExists ($ testFileName , "Generated file ' {$ testFileName }' not found! " );
@@ -261,6 +261,8 @@ public function testSetImageValue()
261
261
$ templateProcessor = new \PhpOffice \PhpWord \TemplateProcessor ($ testFileName );
262
262
unlink ($ testFileName );
263
263
$ templateProcessor ->setImageValue ('Test ' , $ imagePath );
264
+ $ templateProcessor ->setImageValue ('Test1 ' , $ imagePath );
265
+ $ templateProcessor ->setImageValue ('Test2 ' , $ imagePath );
264
266
$ templateProcessor ->saveAs ($ resultFileName );
265
267
$ this ->assertFileExists ($ resultFileName , "Generated file ' {$ resultFileName }' not found! " );
266
268
You can’t perform that action at this time.
0 commit comments