summaryrefslogtreecommitdiffstats
path: root/tests/lib/App/CodeChecker
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2017-06-09 16:45:12 +0200
committerMorris Jobke <hey@morrisjobke.de>2017-07-05 13:02:16 +0200
commit4e5cd1efea7c522ebd763dd3b96eb5f8c0e8407b (patch)
treea184e5b30726048e278f504ebfaa08986a716235 /tests/lib/App/CodeChecker
parent7a3d83d63038e5db0af790b827b73ec7335a6961 (diff)
downloadnextcloud-server-4e5cd1efea7c522ebd763dd3b96eb5f8c0e8407b.tar.gz
nextcloud-server-4e5cd1efea7c522ebd763dd3b96eb5f8c0e8407b.zip
Fix tests of CodeChecker and MigrationService
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests/lib/App/CodeChecker')
-rw-r--r--tests/lib/App/CodeChecker/CodeCheckerTest.php6
-rw-r--r--tests/lib/App/CodeChecker/DeprecationCheckTest.php6
-rw-r--r--tests/lib/App/CodeChecker/NodeVisitorTest.php3
-rw-r--r--tests/lib/App/CodeChecker/StrongComparisonCheckTest.php6
4 files changed, 14 insertions, 7 deletions
diff --git a/tests/lib/App/CodeChecker/CodeCheckerTest.php b/tests/lib/App/CodeChecker/CodeCheckerTest.php
index cdbb7c17da5..bb121eccc44 100644
--- a/tests/lib/App/CodeChecker/CodeCheckerTest.php
+++ b/tests/lib/App/CodeChecker/CodeCheckerTest.php
@@ -23,7 +23,8 @@ class CodeCheckerTest extends TestCase {
*/
public function testFindInvalidUsage($expectedErrorToken, $expectedErrorCode, $fileToVerify) {
$checker = new CodeChecker(
- new PrivateCheck(new EmptyCheck())
+ new PrivateCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
@@ -49,7 +50,8 @@ class CodeCheckerTest extends TestCase {
*/
public function testPassValidUsage($fileToVerify) {
$checker = new CodeChecker(
- new PrivateCheck(new EmptyCheck())
+ new PrivateCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
diff --git a/tests/lib/App/CodeChecker/DeprecationCheckTest.php b/tests/lib/App/CodeChecker/DeprecationCheckTest.php
index ee69f075a61..1a16e7e4920 100644
--- a/tests/lib/App/CodeChecker/DeprecationCheckTest.php
+++ b/tests/lib/App/CodeChecker/DeprecationCheckTest.php
@@ -23,7 +23,8 @@ class DeprecationCheckTest extends TestCase {
*/
public function testFindInvalidUsage($expectedErrorToken, $expectedErrorCode, $fileToVerify) {
$checker = new CodeChecker(
- new DeprecationCheck(new EmptyCheck())
+ new DeprecationCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
@@ -48,7 +49,8 @@ class DeprecationCheckTest extends TestCase {
*/
public function testPassValidUsage($fileToVerify) {
$checker = new CodeChecker(
- new DeprecationCheck(new EmptyCheck())
+ new DeprecationCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
diff --git a/tests/lib/App/CodeChecker/NodeVisitorTest.php b/tests/lib/App/CodeChecker/NodeVisitorTest.php
index ca0b6e9ccc1..d1b1f643677 100644
--- a/tests/lib/App/CodeChecker/NodeVisitorTest.php
+++ b/tests/lib/App/CodeChecker/NodeVisitorTest.php
@@ -59,7 +59,8 @@ class NodeVisitorTest extends TestCase {
*/
public function testMethodsToCheck($expectedErrors, $fileToVerify) {
$checker = new CodeChecker(
- new TestList(new EmptyCheck())
+ new TestList(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
diff --git a/tests/lib/App/CodeChecker/StrongComparisonCheckTest.php b/tests/lib/App/CodeChecker/StrongComparisonCheckTest.php
index c73eae286ab..6d3d2f50efd 100644
--- a/tests/lib/App/CodeChecker/StrongComparisonCheckTest.php
+++ b/tests/lib/App/CodeChecker/StrongComparisonCheckTest.php
@@ -23,7 +23,8 @@ class StrongComparisonCheckTest extends TestCase {
*/
public function testFindInvalidUsage($expectedErrorToken, $expectedErrorCode, $fileToVerify) {
$checker = new CodeChecker(
- new StrongComparisonCheck(new EmptyCheck())
+ new StrongComparisonCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");
@@ -45,7 +46,8 @@ class StrongComparisonCheckTest extends TestCase {
*/
public function testPassValidUsage($fileToVerify) {
$checker = new CodeChecker(
- new StrongComparisonCheck(new EmptyCheck())
+ new StrongComparisonCheck(new EmptyCheck()),
+ false
);
$errors = $checker->analyseFile(\OC::$SERVERROOT . "/tests/data/app/code-checker/$fileToVerify");