function NatWebTestCase::_create_vocabs in Node Auto Term [NAT] 7
Same name and namespace in other branches
- 6.2 tests/nat.test \NatWebTestCase::_create_vocabs()
- 6 tests/nat.test \NatWebTestCase::_create_vocabs()
- 7.2 tests/nat.test \NatWebTestCase::_create_vocabs()
Create two vocabularies for testing.
1 call to NatWebTestCase::_create_vocabs()
- NatWebTestCase::setUp in tests/
nat.test - Sets up a Drupal site for running functional and integration tests.
File
- tests/
nat.test, line 48 - NAT module functionality tests.
Class
- NatWebTestCase
- Base class for all NAT webtest cases.
Code
function _create_vocabs() {
// Create 2 vocabularies
$edit = array(
'name' => $this->nat_vocab1_name,
);
$this
->drupalPost('admin/content/taxonomy/add/vocabulary', $edit, t('Save'));
$edit = array(
'name' => $this->nat_vocab2_name,
);
$this
->drupalPost('admin/content/taxonomy/add/vocabulary', $edit, t('Save'));
$this->nat_vocab1 = $this
->_get_vocabulary_by_name($this->nat_vocab1_name);
$this->nat_vocab2 = $this
->_get_vocabulary_by_name($this->nat_vocab2_name);
}