function i18n_Taxonomy_Test::drupalCreateTerms in Internationalization 6
1 call to i18n_Taxonomy_Test::drupalCreateTerms()
File
- tests/
i18n_taxonomy.test, line 49
Class
Code
function drupalCreateTerms($number = 1, $data = array()) {
$list = array();
for ($i = 1; $i <= $number; $i++) {
$term = $data + array(
'name' => $this
->randomName(10),
'description' => $this
->randomName(20),
);
taxonomy_save_term($term);
$list[] = (object) $term;
}
return $list;
}