function PaymentDeleteFormTest::testSubmitForm in Payment 8.2
@covers ::submitForm
File
- tests/
src/ Unit/ Entity/ Payment/ PaymentDeleteFormTest.php, line 134
Class
- PaymentDeleteFormTest
- @coversDefaultClass \Drupal\payment\Entity\Payment\PaymentDeleteForm
Namespace
Drupal\Tests\payment\Unit\Entity\PaymentCode
function testSubmitForm() {
$this->logger
->expects($this
->atLeastOnce())
->method('info');
$this->payment
->expects($this
->once())
->method('delete');
$form = [];
$form_state = $this
->createMock(FormStateInterface::class);
$form_state
->expects($this
->once())
->method('setRedirect')
->with('<front>');
$this->sut
->submitForm($form, $form_state);
}