예제 #1
0
파일: Form.php 프로젝트: Nycto/Round-Eights
 public function testSetMethod()
 {
     $form = new \r8\Form();
     $this->assertSame("POST", $form->getMethod());
     $this->assertSame($form, $form->setMethod("GET"));
     $this->assertSame("GET", $form->getMethod());
     try {
         $form->setMethod("   ");
         $this->fail("An expected exception was not thrown");
     } catch (\r8\Exception\Argument $err) {
         $this->assertSame("Must not be empty", $err->getMessage());
     }
 }