Skip to content

Commit b3229c6

Browse files
committed
Fix Travis test and update Scrutinizer config
1 parent 37152cd commit b3229c6

File tree

10 files changed

+56
-63
lines changed

10 files changed

+56
-63
lines changed

.scrutinizer.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ before_commands:
77
tools:
88
external_code_coverage:
99
enabled: true
10-
timeout: 700
10+
timeout: 900
1111
php_code_coverage:
1212
enabled: false
1313
test_command: phpunit -c phpunit.xml.dist

.travis.yml

Lines changed: 55 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,68 @@
11
language: php
22

33
php:
4-
- 5.3.3
5-
- 5.3
6-
- 5.4
7-
- 5.5
8-
- 5.6
9-
- hhvm
4+
- 5.3.3
5+
- 5.3
6+
- 5.4
7+
- 5.5
8+
- 5.6
9+
- hhvm
1010

1111
matrix:
12-
allow_failures:
13-
- php: 5.3.3
14-
- php: 5.6
15-
- php: hhvm
12+
allow_failures:
13+
- php: 5.3.3
14+
- php: 5.6
15+
- php: hhvm
1616

1717
env:
18-
global:
19-
- secure: "Sq+6bVtnPsu0mWX8DWQ+9bGAjxMcGorksUiHc4YIXEJsuDfVmVlH8tTD547IeCjDAx9MxXerZ2Z4HSjxTB70VEnJPvZMHI/EZn4Ny31YLHEthdZbV5Gd1h0TGp8VOzPKGShvGrtGBX6MvMfgpK4zuieVWbSfdKeecm8ZNLMpUd4="
18+
global:
19+
- secure: "Sq+6bVtnPsu0mWX8DWQ+9bGAjxMcGorksUiHc4YIXEJsuDfVmVlH8tTD547IeCjDAx9MxXerZ2Z4HSjxTB70VEnJPvZMHI/EZn4Ny31YLHEthdZbV5Gd1h0TGp8VOzPKGShvGrtGBX6MvMfgpK4zuieVWbSfdKeecm8ZNLMpUd4="
2020

2121
before_script:
22-
## Packages
23-
- sudo apt-get -qq update > /dev/null
24-
- sudo apt-get -qq install graphviz > /dev/null
25-
## Composer
26-
# - curl -s http://getcomposer.org/installer | php
27-
# - php composer.phar install --prefer-source
28-
- composer self-update
29-
- composer require dompdf/dompdf:0.6.*
30-
- composer install --prefer-source --dev
31-
## PHP_CodeSniffer
32-
- pyrus install pear/PHP_CodeSniffer
33-
- phpenv rehash
34-
## PHP Copy/Paste Detector
35-
- curl -o phpcpd.phar https://phar.phpunit.de/phpcpd.phar
36-
## PHP Mess Detector
37-
- pear config-set preferred_state beta
38-
- printf "\n" | pecl install imagick
39-
- pear channel-discover pear.phpmd.org
40-
- pear channel-discover pear.pdepend.org
41-
- pear install --alldeps phpmd/PHP_PMD
42-
- phpenv rehash
43-
## PHPLOC
44-
#- curl -o phploc.phar https://phar.phpunit.de/phploc.phar
45-
## PHPDocumentor
46-
- mkdir -p build/docs
47-
- mkdir -p build/coverage
22+
## Packages
23+
- sudo apt-get -qq update > /dev/null
24+
- sudo apt-get -qq install graphviz > /dev/null
25+
## Composer
26+
# - curl -s http://getcomposer.org/installer | php
27+
# - php composer.phar install --prefer-source
28+
- composer self-update
29+
- composer require dompdf/dompdf:0.6.*
30+
- composer install --prefer-source --dev
31+
## PHP_CodeSniffer
32+
- pyrus install pear/PHP_CodeSniffer
33+
- phpenv rehash
34+
## PHP Copy/Paste Detector
35+
- curl -o phpcpd.phar https://phar.phpunit.de/phpcpd.phar
36+
## PHP Mess Detector
37+
- pear config-set preferred_state beta
38+
- printf "\n" | pecl install imagick
39+
- pear channel-discover pear.phpmd.org
40+
- pear channel-discover pear.pdepend.org
41+
- pear install --alldeps phpmd/PHP_PMD
42+
- phpenv rehash
43+
## PHPLOC
44+
#- curl -o phploc.phar https://phar.phpunit.de/phploc.phar
45+
## PHPDocumentor
46+
- mkdir -p build/docs
47+
- mkdir -p build/coverage
4848

4949
script:
50-
## PHP_CodeSniffer
51-
- phpcs src/ tests/ --standard=PSR2 -n --ignore=src/PhpWord/Shared/PCLZip
52-
## PHP Copy/Paste Detector
53-
- php phpcpd.phar src/ tests/ --verbose
54-
## PHP Mess Detector
55-
- phpmd src/,tests/ text unusedcode,naming,design,controversial --exclude pclzip.lib.php
56-
## PHPLOC
57-
#- php phploc.phar src/
58-
## PHPUnit
59-
- phpunit -c ./ --coverage-text --coverage-html ./build/coverage
60-
## PHPDocumentor
61-
- vendor/bin/phpdoc.php -d ./src -t ./build/docs --ignore "*/src/PhpWord/Shared/PCLZip/*" --template="responsive-twig"
50+
## PHP_CodeSniffer
51+
- phpcs src/ tests/ --standard=PSR2 -n --ignore=src/PhpWord/Shared/PCLZip
52+
## PHP Copy/Paste Detector
53+
- php phpcpd.phar src/ tests/ --verbose
54+
## PHP Mess Detector
55+
- phpmd src/,tests/ text unusedcode,naming,design,controversial --exclude pclzip.lib.php
56+
## PHPLOC
57+
#- php phploc.phar src/
58+
## PHPUnit
59+
- phpunit -c ./ --coverage-text --coverage-html ./build/coverage
60+
## PHPDocumentor
61+
- vendor/bin/phpdoc.php -d ./src -t ./build/docs --ignore "*/src/PhpWord/Shared/PCLZip/*" --template="responsive-twig"
6262

6363
after_script:
64-
## PHPDocumentor
65-
- bash .travis_shell_after_success.sh
66-
- wget https://scrutinizer-ci.com/ocular.phar
67-
- php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml
64+
## PHPDocumentor
65+
- bash .travis_shell_after_success.sh
66+
## Scrutinizer
67+
- wget https://scrutinizer-ci.com/ocular.phar
68+
- php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml

src/PhpWord/Template.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,6 @@ public function cloneRow($search, $numberOfClones)
235235
public function cloneBlock($blockname, $clones = 1, $replace = true)
236236
{
237237
$xmlBlock = null;
238-
$pattern =
239238
preg_match(
240239
'/(<\?xml.*)(<w:p.*>\${' . $blockname . '}<\/w:.*?p>)(.*)(<w:p.*\${\/' . $blockname . '}<\/w:.*?p>)/is',
241240
$this->documentXML,

src/PhpWord/Writer/ODText/Part/Content.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919

2020
use PhpOffice\PhpWord\Element\Table;
2121
use PhpOffice\PhpWord\Element\Text;
22-
use PhpOffice\PhpWord\Exception\Exception;
2322
use PhpOffice\PhpWord\Media;
2423
use PhpOffice\PhpWord\PhpWord;
2524
use PhpOffice\PhpWord\Shared\XMLWriter;

src/PhpWord/Writer/ODText/Part/Meta.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpWord\Writer\ODText\Part;
1919

20-
use PhpOffice\PhpWord\Exception\Exception;
2120
use PhpOffice\PhpWord\PhpWord;
2221

2322
/**

src/PhpWord/Writer/ODText/Part/Styles.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpWord\Writer\ODText\Part;
1919

20-
use PhpOffice\PhpWord\Exception\Exception;
2120
use PhpOffice\PhpWord\PhpWord;
2221
use PhpOffice\PhpWord\Style;
2322

src/PhpWord/Writer/Word2007/Part/DocPropsApp.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpWord\Writer\Word2007\Part;
1919

20-
use PhpOffice\PhpWord\Exception\Exception;
2120
use PhpOffice\PhpWord\PhpWord;
2221

2322
/**

src/PhpWord/Writer/Word2007/Part/DocPropsCore.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpWord\Writer\Word2007\Part;
1919

20-
use PhpOffice\PhpWord\Exception\Exception;
2120
use PhpOffice\PhpWord\PhpWord;
2221

2322
/**

src/PhpWord/Writer/Word2007/Part/Document.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
namespace PhpOffice\PhpWord\Writer\Word2007\Part;
1919

2020
use PhpOffice\PhpWord\Element\Section;
21-
use PhpOffice\PhpWord\Exception\Exception;
2221
use PhpOffice\PhpWord\PhpWord;
2322
use PhpOffice\PhpWord\Shared\XMLWriter;
2423
use PhpOffice\PhpWord\Writer\Word2007\Style\Section as SectionStyleWriter;

src/PhpWord/Writer/Word2007/Part/Styles.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpWord\Writer\Word2007\Part;
1919

20-
use PhpOffice\PhpWord\Exception\Exception;
2120
use PhpOffice\PhpWord\PhpWord;
2221
use PhpOffice\PhpWord\Shared\XMLWriter;
2322
use PhpOffice\PhpWord\Style;

0 commit comments

Comments
 (0)