Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for checking test code coverage #560

Merged
merged 3 commits into from
Aug 1, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
build/
vendor/
composer.lock
phpcs.xml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the DeclarationCompatibility sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Classes\DeclarationCompatibilitySniff
*/
class DeclarationCompatibilityUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the RestrictedExtendClasses sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Classes\RestrictedExtendClassesSniff
*/
class RestrictedExtendClassesUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the CheckReturnValue sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Compatibility\ZoninatorSniff
*/
class ZoninatorUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the ConstantString sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Constants\ConstantStringSniff
*/
class ConstantStringUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the ConstantRestrictions sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Constants\RestrictedConstantsSniff
*/
class RestrictedConstantsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Files/IncludingFileUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
* Unit test class for the IncludingFile sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Files\IncludingFileSniff
*/
class IncludingFileUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
* Unit test class for the IncludingFile sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Files\IncludingNonPHPFileSniff
*/
class IncludingNonPHPFileUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the CheckReturnValue sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Functions\CheckReturnValueSniff
*/
class CheckReturnValueUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the DynamicCalls sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Functions\DynamicCallsSniff
*/
class DynamicCallsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the RestrictedFunctions sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Functions\RestrictedFunctionsSniff
*/
class RestrictedFunctionsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Functions/StripTagsUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the StripTags sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Functions\StripTagsSniff
*/
class StripTagsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
* Unit test class for the Hooks/AlwaysReturn sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Hooks\AlwaysReturnInFilterSniff
*/
class AlwaysReturnInFilterUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Hooks/PreGetPostsUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the PreGetPosts sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Hooks\PreGetPostsSniff
*/
class PreGetPostsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Hooks/RestrictedHooksUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
* @package VIPCS\WordPressVIPMinimum
*
* @since 0.4.0
*
* @covers \WordPressVIPMinimum\Sniffs\Hooks\RestrictedHooksSniff
*/
class RestrictedHooksUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the HTML String concatenation in JS sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\DangerouslySetInnerHTMLSniff
*/
class DangerouslySetInnerHTMLUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the HTML executing JS functions sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\HTMLExecutingFunctionsSniff
*/
class HTMLExecutingFunctionsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/JS/InnerHTMLUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the HTML String concatenation in JS sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\InnerHTMLSniff
*/
class InnerHTMLUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/JS/StringConcatUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the HTML String concatenation in JS sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\StringConcatSniff
*/
class StringConcatUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/JS/StrippingTagsUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for incorrect HTML tags stripping approach in JS sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\StrippingTagsSniff
*/
class StrippingTagsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/JS/WindowUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the HTML String concatenation in JS sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\JS\WindowSniff
*/
class WindowUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the BatcacheWhitelistedParams sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\BatcacheWhitelistedParamsSniff
*/
class BatcacheWhitelistedParamsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the CacheValueOverride sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\CacheValueOverrideSniff
*/
class CacheValueOverrideUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the ExitAfterRedirect sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\FetchingRemoteDataSniff
*/
class FetchingRemoteDataUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the LowExpiryCacheTime sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\LowExpiryCacheTimeSniff
*/
class LowExpiryCacheTimeUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Performance/NoPagingUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
* @package VIPCS\WordPressVIPMinimum
*
* @since 0.5.0
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\NoPagingSniff
*/
class NoPagingUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
* @package VIPCS\WordPressVIPMinimum
*
* @since 0.5.0
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\OrderByRandSniff
*/
class OrderByRandUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the RegexpCompare sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\RegexpCompareSniff
*/
class RegexpCompareUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the RemoteRequestTimeout sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\RemoteRequestTimeoutSniff
*/
class RemoteRequestTimeoutUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the TaxonomyMetaInOptions sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\TaxonomyMetaInOptionsSniff
*/
class TaxonomyMetaInOptionsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the WP_Query params sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Performance\WPQueryParamsSniff
*/
class WPQueryParamsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the EscapingVoidReturnFunctions sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\EscapingVoidReturnFunctionsSniff
*/
class EscapingVoidReturnFunctionsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the ExitAfterRedirect sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\ExitAfterRedirectSniff
*/
class ExitAfterRedirectUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Security/MustacheUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the unescaped output in Mustache templating engine.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\MustacheSniff
*/
class MustacheUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the WP_Query params sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\PHPFilterFunctionsSniff
*/
class PHPFilterFunctionsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the ProperEscapingFunction sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\ProperEscapingFunctionSniff
*/
class ProperEscapingFunctionUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the StaticStrreplace sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\StaticStrreplaceSniff
*/
class StaticStrreplaceUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Security/TwigUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the unescaped output in Twig templating engine.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\TwigSniff
*/
class TwigUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Security/UnderscorejsUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the unescaped output in Underscore.js templating engine.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\UnderscorejsSniff
*/
class UnderscorejsUnitTest extends AbstractSniffUnitTest {

Expand Down
2 changes: 2 additions & 0 deletions WordPressVIPMinimum/Tests/Security/VuejsUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the unescaped output in Vue.js templating engine.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Security\VuejsSniff
*/
class VuejsUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
* @package VIPCS\WordPressVIPMinimum
*
* @since 0.5.0
*
* @covers \WordPressVIPMinimum\Sniffs\UserExperience\AdminBarRemovalSniff
*/
class AdminBarRemovalUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
*
* @since 0.3.0
* @since 0.13.0 Class name changed: this class is now namespaced.
*
* @covers \WordPressVIPMinimum\Sniffs\Variables\RestrictedVariablesSniff
*/
class RestrictedVariablesUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the Variable Analysis sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Variables\ServerVariablesSniff
*/
class ServerVariablesUnitTest extends AbstractSniffUnitTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* Unit test class for the Variable Analysis sniff.
*
* @package VIPCS\WordPressVIPMinimum
*
* @covers \WordPressVIPMinimum\Sniffs\Variables\VariableAnalysisSniff
*/
class VariableAnalysisUnitTest extends AbstractSniffUnitTest {

Expand Down
Loading