public function PathologicUITest::doTestSettingsForm in Pathologic 8
Test settings form.
1 call to PathologicUITest::doTestSettingsForm()
- PathologicUITest::testPathologicUi in tests/
src/ Functional/ PathologicUITest.php - Tests for the Pathologic UI.
File
- tests/
src/ Functional/ PathologicUITest.php, line 46
Class
- PathologicUITest
- Tests for the Pathologic UI.
Namespace
Drupal\Tests\pathologic\FunctionalCode
public function doTestSettingsForm() {
$this
->drupalGet('admin/config/content/pathologic');
$this
->assertText('Pathologic configuration');
// Test submit form.
$this
->assertNoFieldChecked('edit-protocol-style-proto-rel');
$edit = [
'protocol_style' => 'proto-rel',
'local_paths' => 'http://example.com/',
];
$this
->drupalPostForm(NULL, $edit, t('Save configuration'));
$this
->assertText('The configuration options have been saved.');
$this
->assertFieldChecked('edit-protocol-style-proto-rel');
$this
->assertText('http://example.com/');
$this
->clickLink('Pathologic’s documentation');
$this
->assertResponse(200);
}