| @@ 34-40 (lines=7) @@ | ||
| 31 | * |
|
| 32 | * @return void |
|
| 33 | */ |
|
| 34 | public function testApplyIgnoresMethodsWithLessParametersThanMinimum() |
|
| 35 | { |
|
| 36 | $rule = new LongParameterList(); |
|
| 37 | $rule->setReport($this->getReportMock(0)); |
|
| 38 | $rule->addProperty('minimum', '4'); |
|
| 39 | $rule->apply($this->createMethod(3)); |
|
| 40 | } |
|
| 41 | ||
| 42 | /** |
|
| 43 | * testApplyReportsMethodsWithIdenticalParametersAndMinimum |
|
| @@ 47-53 (lines=7) @@ | ||
| 44 | * |
|
| 45 | * @return void |
|
| 46 | */ |
|
| 47 | public function testApplyReportsMethodsWithIdenticalParametersAndMinimum() |
|
| 48 | { |
|
| 49 | $rule = new LongParameterList(); |
|
| 50 | $rule->setReport($this->getReportMock(1)); |
|
| 51 | $rule->addProperty('minimum', '3'); |
|
| 52 | $rule->apply($this->createMethod(3)); |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * testApplyReportsMethodsWithMoreParametersThanMinimum |
|
| @@ 60-66 (lines=7) @@ | ||
| 57 | * |
|
| 58 | * @return void |
|
| 59 | */ |
|
| 60 | public function testApplyReportsMethodsWithMoreParametersThanMinimum() |
|
| 61 | { |
|
| 62 | $rule = new LongParameterList(); |
|
| 63 | $rule->setReport($this->getReportMock(1)); |
|
| 64 | $rule->addProperty('minimum', '3'); |
|
| 65 | $rule->apply($this->createMethod(42)); |
|
| 66 | } |
|
| 67 | ||
| 68 | /** |
|
| 69 | * testApplyIgnoresFunctionsWithLessParametersThanMinimum |
|
| @@ 73-79 (lines=7) @@ | ||
| 70 | * |
|
| 71 | * @return void |
|
| 72 | */ |
|
| 73 | public function testApplyIgnoresFunctionsWithLessParametersThanMinimum() |
|
| 74 | { |
|
| 75 | $rule = new LongParameterList(); |
|
| 76 | $rule->setReport($this->getReportMock(0)); |
|
| 77 | $rule->addProperty('minimum', '4'); |
|
| 78 | $rule->apply($this->createFunction(3)); |
|
| 79 | } |
|
| 80 | ||
| 81 | /** |
|
| 82 | * testApplyReportsFunctionsWithIdenticalParametersAndMinimum |
|
| @@ 86-92 (lines=7) @@ | ||
| 83 | * |
|
| 84 | * @return void |
|
| 85 | */ |
|
| 86 | public function testApplyReportsFunctionsWithIdenticalParametersAndMinimum() |
|
| 87 | { |
|
| 88 | $rule = new LongParameterList(); |
|
| 89 | $rule->setReport($this->getReportMock(1)); |
|
| 90 | $rule->addProperty('minimum', '3'); |
|
| 91 | $rule->apply($this->createFunction(3)); |
|
| 92 | } |
|
| 93 | ||
| 94 | /** |
|
| 95 | * testApplyReportsFunctionsWithMoreParametersThanMinimum |
|
| @@ 99-105 (lines=7) @@ | ||
| 96 | * |
|
| 97 | * @return void |
|
| 98 | */ |
|
| 99 | public function testApplyReportsFunctionsWithMoreParametersThanMinimum() |
|
| 100 | { |
|
| 101 | $rule = new LongParameterList(); |
|
| 102 | $rule->setReport($this->getReportMock(1)); |
|
| 103 | $rule->addProperty('minimum', '3'); |
|
| 104 | $rule->apply($this->createFunction(42)); |
|
| 105 | } |
|
| 106 | ||
| 107 | /** |
|
| 108 | * Returns a mocked method instance. |
|