Issue #1893336 by dawehner: Fixed Views Machine name field does not work.
parent
f26efbe105
commit
2575651a83
|
@ -139,4 +139,15 @@ class BasicTest extends WizardTestBase {
|
||||||
$this->assertNoText('tracker', t('Default tracker view does not show on the listing page.'));
|
$this->assertNoText('tracker', t('Default tracker view does not show on the listing page.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Tests the actual wizard form.
|
||||||
|
*
|
||||||
|
* @see \Drupal\views_ui\ViewAddFormController::form()
|
||||||
|
*/
|
||||||
|
protected function testWizardForm() {
|
||||||
|
$this->drupalGet('admin/structure/views/add');
|
||||||
|
|
||||||
|
$result = $this->xpath('//small[@id = "edit-human-name-machine-name-suffix"]');
|
||||||
|
$this->assertTrue(count($result), 'Ensure that the machine name is applied to the name field.');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ class ViewAddFormController extends ViewFormControllerBase {
|
||||||
'#maxlength' => 128,
|
'#maxlength' => 128,
|
||||||
'#machine_name' => array(
|
'#machine_name' => array(
|
||||||
'exists' => 'views_get_view',
|
'exists' => 'views_get_view',
|
||||||
'source' => array('id', 'human_name'),
|
'source' => array('name', 'human_name'),
|
||||||
),
|
),
|
||||||
'#description' => t('A unique machine-readable name for this View. It must only contain lowercase letters, numbers, and underscores.'),
|
'#description' => t('A unique machine-readable name for this View. It must only contain lowercase letters, numbers, and underscores.'),
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in New Issue