Exemple #1
0
 public function testSetPeriodAndLimit()
 {
     $actionLimit = new CM_Model_ActionLimit_AbstractMock($this->_actionType, $this->_actionVerb);
     $result = $actionLimit->setLimitAndPeriod(12, 13, 14);
     $this->assertSame(13, $actionLimit->getLimit(12));
     $this->assertSame(14, $actionLimit->getPeriod(12));
     $this->assertEquals($actionLimit, $result);
 }
Exemple #2
0
 public function testJsonSerialize()
 {
     $actionLimit = new CM_Model_ActionLimit_AbstractMock($this->_actionType, $this->_actionVerb);
     $this->assertEquals(['actionType' => $this->_actionType, 'actionVerb' => $this->_actionVerb], $actionLimit->jsonSerialize());
 }