From 1199a5a974778f105a785f0724e3213061cdc9b5 Mon Sep 17 00:00:00 2001 From: Glomberg Date: Mon, 25 Sep 2023 13:37:53 +0300 Subject: [PATCH] Upd. Library code updated. --- .../HeuristicAnalyser/tests/.phpcs.xml | 30 ------------------- .../tests/Scanner/HTMLTest.php | 29 ------------------ .../tests/Scanner/TokensTest.php | 26 ---------------- .../HeuristicAnalyser/tests/bootstrap.php | 22 -------------- .../HeuristicAnalyser/tests/phpunit.xml | 17 ----------- .../SignaturesAnalyser/tests/.phpcs.xml | 30 ------------------- .../SignaturesAnalyser/tests/bootstrap.php | 1 - .../SignaturesAnalyser/tests/phpunit.xml | 17 ----------- 8 files changed, 172 deletions(-) delete mode 100644 lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/.phpcs.xml delete mode 100644 lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/HTMLTest.php delete mode 100644 lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/TokensTest.php delete mode 100644 lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/bootstrap.php delete mode 100644 lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/phpunit.xml delete mode 100644 lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/.phpcs.xml delete mode 100644 lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/bootstrap.php delete mode 100644 lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/phpunit.xml diff --git a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/.phpcs.xml b/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/.phpcs.xml deleted file mode 100644 index 10ccec065..000000000 --- a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/.phpcs.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - Sniff code to check different PHP compatibility - - - ../ - /vendor/ - /lib/ - - - - - - - - - - tests/* - vendor/* - fw_files/* - - - - - - - - - - diff --git a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/HTMLTest.php b/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/HTMLTest.php deleted file mode 100644 index a31814267..000000000 --- a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/HTMLTest.php +++ /dev/null @@ -1,29 +0,0 @@ -alert(1);' - ); - ?> - - "; - $tokens = new Tokens($file_content); - $this->html = new HTML($tokens); - } - - public function testAnalise() - { - $this->html->analise(); - $this->assertEquals('T_INLINE_HTML', $this->html->result); - } -} diff --git a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/TokensTest.php b/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/TokensTest.php deleted file mode 100644 index 966e84bbe..000000000 --- a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/Scanner/TokensTest.php +++ /dev/null @@ -1,26 +0,0 @@ -tokens = new Tokens($file_content); - } - - public function testGetTokenFromPosition() - { - $echo_token = $this->tokens->getTokenFromPosition(2); - $this->assertInstanceOf(Token::class, $echo_token); - $this->assertEquals($echo_token[0], 'T_ECHO'); - $this->assertEquals($echo_token[1], 'echo'); - } -} diff --git a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/bootstrap.php b/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/bootstrap.php deleted file mode 100644 index 7386fad60..000000000 --- a/lib/CleantalkSP/Common/Scanner/HeuristicAnalyser/tests/bootstrap.php +++ /dev/null @@ -1,22 +0,0 @@ - - - - - ./ - ./bootstrap.php - - - diff --git a/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/.phpcs.xml b/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/.phpcs.xml deleted file mode 100644 index f21f21787..000000000 --- a/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/.phpcs.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - Sniff code to check different PHP compatibility - - - ../ - /vendor/ - /lib/ - - - - - - - - - - tests/* - vendor/* - fw_files/* - - - - - - - - - - diff --git a/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/bootstrap.php b/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/bootstrap.php deleted file mode 100644 index b3d9bbc7f..000000000 --- a/lib/CleantalkSP/Common/Scanner/SignaturesAnalyser/tests/bootstrap.php +++ /dev/null @@ -1 +0,0 @@ - - - - - ./ - ./bootstrap.php - - -