Explorar o código

Add Exception test

Thomas Rabaix %!s(int64=13) %!d(string=hai) anos
pai
achega
efb17ab69b
Modificáronse 1 ficheiros con 9 adicións e 0 borrados
  1. 9 0
      Tests/Filter/ORM/FilterTest.php

+ 9 - 0
Tests/Filter/ORM/FilterTest.php

@@ -64,4 +64,13 @@ class FilterTest extends \PHPUnit_Framework_TestCase
         $filter->setValue(42);
         $this->assertEquals(42, $filter->getValue());
     }
+
+    /**
+     * @expectedException RuntimeException
+     */
+    public function testExceptionOnEmptyFieldName()
+    {
+        $filter = new FilterTest_Filter();
+        $filter->getFieldName();
+    }
 }