chore: Drop app code checker test data

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
pull/38550/head
Christoph Wurst 3 years ago
parent 2845a04827
commit 315f7f286f
No known key found for this signature in database
GPG Key ID: CC42AC2A7F0E56D8
  1. 10
      tests/data/app/code-checker/test-const.php
  2. 8
      tests/data/app/code-checker/test-deprecated-constant-alias.php
  3. 8
      tests/data/app/code-checker/test-deprecated-constant-sub-alias.php
  4. 8
      tests/data/app/code-checker/test-deprecated-constant-sub.php
  5. 6
      tests/data/app/code-checker/test-deprecated-constant.php
  6. 6
      tests/data/app/code-checker/test-deprecated-function-alias.php
  7. 6
      tests/data/app/code-checker/test-deprecated-function-sub-alias.php
  8. 6
      tests/data/app/code-checker/test-deprecated-function-sub.php
  9. 4
      tests/data/app/code-checker/test-deprecated-function.php
  10. 5
      tests/data/app/code-checker/test-deprecated-method.php
  11. 9
      tests/data/app/code-checker/test-deprecated-use-alias.php
  12. 9
      tests/data/app/code-checker/test-deprecated-use-sub-alias.php
  13. 9
      tests/data/app/code-checker/test-deprecated-use-sub.php
  14. 9
      tests/data/app/code-checker/test-deprecated-use.php
  15. 11
      tests/data/app/code-checker/test-equal.php
  16. 8
      tests/data/app/code-checker/test-extends.php
  17. 13
      tests/data/app/code-checker/test-identical-operator.php
  18. 9
      tests/data/app/code-checker/test-implements.php
  19. 10
      tests/data/app/code-checker/test-new.php
  20. 11
      tests/data/app/code-checker/test-not-equal.php
  21. 10
      tests/data/app/code-checker/test-static-call.php
  22. 12
      tests/data/app/code-checker/test-use.php

@ -1,10 +0,0 @@
<?php
/**
* Class BadClass - accessing consts on blacklisted classes is not allowed
*/
class BadClass {
public function foo() {
$bar = \OC_API::ADMIN_AUTH;
}
}

@ -1,8 +0,0 @@
<?php
use OCP\NamespaceName\ClassName as Alias;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
Alias::CONSTANT_NAME;

@ -1,8 +0,0 @@
<?php
use OCP\NamespaceName as SubAlias;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
SubAlias\ClassName::CONSTANT_NAME;

@ -1,8 +0,0 @@
<?php
use OCP\NamespaceName;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
NamespaceName\ClassName::CONSTANT_NAME;

@ -1,6 +0,0 @@
<?php
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
\OCP\NamespaceName\ClassName::CONSTANT_NAME;

@ -1,6 +0,0 @@
<?php
use OCP\NamespaceName\ClassName as Alias;
Alias::functionName();
Alias::methodName();

@ -1,6 +0,0 @@
<?php
use OCP\NamespaceName as SubAlias;
SubAlias\ClassName::functionName();
SubAlias\ClassName::methodName();

@ -1,6 +0,0 @@
<?php
use OCP\NamespaceName;
NamespaceName\ClassName::functionName();
NamespaceName\ClassName::methodName();

@ -1,4 +0,0 @@
<?php
\OCP\NamespaceName\ClassName::functionName();
\OCP\NamespaceName\ClassName::methodName();

@ -1,5 +0,0 @@
<?php
$class = new \OCP\NamespaceName\ClassName();
$class->methodName();
$class::methodName();

@ -1,9 +0,0 @@
<?php
use OCP\AppFramework\IApi as OAFIA;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass implements OAFIA {
}

@ -1,9 +0,0 @@
<?php
use OCP\AppFramework as OAF;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass implements OAF\IApi {
}

@ -1,9 +0,0 @@
<?php
use OCP\AppFramework;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass implements AppFramework\IApi {
}

@ -1,9 +0,0 @@
<?php
use OCP\AppFramework\IApi;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass implements IApi {
}

@ -1,11 +0,0 @@
<?php
/**
* Class BadClass - uses equal instead of identical operator
*/
class BadClass {
public function foo() {
if (true == false) {
}
}
}

@ -1,8 +0,0 @@
<?php
/**
* Class BadClass - sub class a forbidden class is not allowed
*/
class BadClass extends OC_Hook {
}

@ -1,13 +0,0 @@
<?php
/**
* Class GoodClass - uses identical operator
*/
class GoodClass {
public function foo() {
if (true === false) {
}
if (true !== false) {
}
}
}

@ -1,9 +0,0 @@
<?php
/**
* Class BadClass - sub class a forbidden class is not allowed
* NOTE: lowercase typo is intended
*/
class BadClass implements oC_Avatar {
}

@ -1,10 +0,0 @@
<?php
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass {
public function foo() {
$bar = new OC_AppConfig();
}
}

@ -1,11 +0,0 @@
<?php
/**
* Class BadClass - uses equal instead of identical operator
*/
class BadClass {
public function foo() {
if (true != false) {
}
}
}

@ -1,10 +0,0 @@
<?php
/**
* Class BadClass - calling static methods on blacklisted classes is not allowed
*/
class BadClass {
public function foo() {
OC_App::isEnabled('bar');
}
}

@ -1,12 +0,0 @@
<?php
use OC_AppConfig as UseConfig;
/**
* Class BadClass - creating an instance of a blacklisted class is not allowed
*/
class BadClass {
public function foo() {
$bar = new UseConfig();
}
}
Loading…
Cancel
Save