Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / web / core / modules / system / tests / src / Functional / Form / SystemConfigFormTest.php
1 <?php
2
3 namespace Drupal\Tests\system\Functional\Form;
4
5 use Drupal\Tests\BrowserTestBase;
6
7 /**
8  * Tests the SystemConfigFormTestBase class.
9  *
10  * @group Form
11  */
12 class SystemConfigFormTest extends BrowserTestBase {
13
14   /**
15    * Modules to enable.
16    *
17    * @var array
18    */
19   public static $modules = ['form_test'];
20
21   /**
22    * Tests the SystemConfigFormTestBase class.
23    */
24   public function testSystemConfigForm() {
25     $this->drupalGet('form-test/system-config-form');
26     $element = $this->xpath('//div[@id = :id]/input[contains(@class, :class)]', [':id' => 'edit-actions', ':class' => 'button--primary']);
27     $this->assertTrue($element, 'The primary action submit button was found.');
28     $this->drupalPostForm(NULL, [], t('Save configuration'));
29     $this->assertText(t('The configuration options have been saved.'));
30   }
31
32 }