lib/Weathermap/Tests/GeometryTest.php
Method testVector
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function testVector()
{
$infiniteSlope = 10000000000.0;
$vector1 = new Vector(0, 0);
Method testPoint
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function testPoint()
{
$point1 = new Point(10, 13);
$point2 = new Point(-40, 40);
$point3 = new Point(30, 33);
Remove this commented out code. Open
Open
// $vector2 = $point1->vectorToPoint($point2);
- Read upRead up
- Exclude checks
Programmers should not comment out code as it bloats programs and reduces readability.
Unused code should be deleted and can be retrieved from source control history if required.
See
- MISRA C:2004, 2.4 - Sections of code should not be "commented out".
- MISRA C++:2008, 2-7-2 - Sections of code shall not be "commented out" using C-style comments.
- MISRA C++:2008, 2-7-3 - Sections of code should not be "commented out" using C++ comments.
- MISRA C:2012, Dir. 4.4 - Sections of code should not be "commented out"
Remove this commented out code. Open
Open
//require_once dirname(__FILE__).'/../lib/all.php';
- Read upRead up
- Exclude checks
Programmers should not comment out code as it bloats programs and reduces readability.
Unused code should be deleted and can be retrieved from source control history if required.
See
- MISRA C:2004, 2.4 - Sections of code should not be "commented out".
- MISRA C++:2008, 2-7-2 - Sections of code shall not be "commented out" using C-style comments.
- MISRA C++:2008, 2-7-3 - Sections of code should not be "commented out" using C++ comments.
- MISRA C:2012, Dir. 4.4 - Sections of code should not be "commented out"