コード例 #1
0
ファイル: ActionSetTest.php プロジェクト: DrupalTV/DrupalTV
 /**
  * Tests deleting an action from the container.
  */
 public function testDeletingAction()
 {
     $this->actionSet->addExpressionObject($this->testActionExpression->reveal());
     $second_action = $this->prophesize(RulesAction::class);
     $this->actionSet->addExpressionObject($second_action->reveal());
     // Get the UUID of the first action added.
     $uuid = $this->actionSet->getIterator()->key();
     $this->actionSet->deleteExpression($uuid);
     // Now only the second action remains.
     foreach ($this->actionSet as $action) {
         $this->assertSame($second_action->reveal(), $action);
     }
 }