Skip to content

Commit cad07c9

Browse files
committed
Add PHPCS
1 parent 65a3faa commit cad07c9

11 files changed

+66
-13
lines changed

.travis.yml

+1
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ before_script:
55
- composer install
66
script:
77
- vendor/bin/phpunit
8+
- vendor/bin/phpcs --standard=PSR2 -n scr tests

composer.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@
1919
"php": ">=7.0"
2020
},
2121
"require-dev": {
22-
"phpunit/phpunit": "^6.1"
22+
"phpunit/phpunit": "^6.1",
23+
"squizlabs/php_codesniffer": "^3.1"
2324
},
2425
"autoload": {
2526
"psr-4": {

composer.lock

+55-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Exception/ErrorCommandExecutable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ public function __construct($message = "", $code = 0, Exception $previous = null
1717
$message = 'Your report has an error and couldn \'t be processed!\ Try to output the command using the function `output();` and run it manually in the console.';
1818
parent::__construct($message, $code, $previous);
1919
}
20-
}
20+
}

src/Exception/InvalidCommandExecutable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ public function __construct($message = "", $code = 0, Exception $previous = null
1717
$message = 'Cannot execute a blank command';
1818
parent::__construct($message, $code, $previous);
1919
}
20-
}
20+
}

src/Exception/InvalidFormat.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ public function __construct($message = "", $code = 0, Exception $previous = null
1616
{
1717
parent::__construct($message, $code, $previous);
1818
}
19-
}
19+
}

src/Exception/InvalidInputFile.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ public function __construct($message = "", $code = 0, Exception $previous = null
1717
$message = 'No input file';
1818
parent::__construct($message, $code, $previous);
1919
}
20-
}
20+
}

src/Exception/InvalidResourceDirectory.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ public function __construct($message = "", $code = 0, Exception $previous = null
1818
$message = 'Invalid resource directory';
1919
parent::__construct($message, $code, $previous);
2020
}
21-
}
21+
}

src/PHPJasper.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -253,4 +253,4 @@ protected function validateExecute()
253253
throw new \PHPJasper\Exception\InvalidResourceDirectory();
254254
}
255255
}
256-
}
256+
}

tests/PHPJasper/PHPJasperTest.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
* @author Rafael Queiroz <[email protected]>
2121
*/
2222
class PHPJasperTest extends TestCase
23-
2423
{
2524
public function setUp()
2625
{
@@ -137,4 +136,4 @@ public function testProcess()
137136
$jasper = new PHPJasper();
138137
$this->assertInstanceOf(PHPJasper::class, $jasper->process('hello_world.jrxml', ""));
139138
}
140-
}
139+
}

tests/bootstrap.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
<?php
22

3-
require_once __DIR__ . '/../vendor/autoload.php';
3+
require_once __DIR__ . '/../vendor/autoload.php';

0 commit comments

Comments
 (0)