Browse Source

Add Exception test

Thomas Rabaix 13 năm trước cách đây
mục cha
commit
efb17ab69b
1 tập tin đã thay đổi với 9 bổ sung0 xóa
  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();
+    }
 }