/**
  * testFormalParameterUsedInDoubleQuoteStringGetsNotReported
  *
  * @return void
  */
 public function testFormalParameterUsedInDoubleQuoteStringGetsNotReported()
 {
     $rule = new PHP_PMD_Rule_UnusedFormalParameter();
     $rule->setReport($this->getReportMock(0));
     $rule->apply($this->getMethod());
 }
コード例 #2
0
 /**
  * testRuleDoesNotApplyToImplementedInterfaceMethod
  *
  * @return void
  * @since 1.2.1
  */
 public function testRuleDoesNotApplyToImplementedInterfaceMethod()
 {
     $rule = new PHP_PMD_Rule_UnusedFormalParameter();
     $rule->setReport($this->getReportMock(0));
     $rule->apply($this->getMethod());
 }
コード例 #3
0
 /**
  * testRuleDoesNotApplyToInnerFunctionDeclaration
  *
  * @return void
  * @covers PHP_PMD_Rule_UnusedFormalParameter
  * @group phpmd
  * @group phpmd::rule
  * @group unittest
  */
 public function testRuleDoesNotApplyToInnerFunctionDeclaration()
 {
     $rule = new PHP_PMD_Rule_UnusedFormalParameter();
     $rule->setReport($this->getReportMock(0));
     $rule->apply($this->getFunction());
 }
コード例 #4
0
 /**
  * testRuleDoesNotApplyToMethodWithFuncGetArgs
  *
  * If func_get_args() is called then all parameters are
  * automatically referenced without needing them to be referenced
  * explicitly
  * 
  * <code>
  * class Foo {
  *     function bar($baz) {
  *         print_r(func_get_args());
  *     }
  * }
  * </code>
  * @group phpmd
  * @group phpmd::rule
  * @group unittest
  */
 public function testRuleDoesNotApplyToMethodWithFuncGetArgs()
 {
     $rule = new PHP_PMD_Rule_UnusedFormalParameter();
     $rule->setReport($this->getReportMock(0));
     $rule->apply($this->getMethod());
 }