You are here

function BiblioKeywordWebTestCase::createKeyword in Bibliography Module 7.2

Same name and namespace in other branches
  1. 6.2 tests/keyword.test \BiblioKeywordWebTestCase::createKeyword()
  2. 7 tests/BiblioKeywordWebTestCase.test \BiblioKeywordWebTestCase::createKeyword()

Returns a new keyword with random properties.

6 calls to BiblioKeywordWebTestCase::createKeyword()
BiblioKeywordUnitTest::testBiblioDeleteKeyword in tests/keyword.test
BiblioKeywordUnitTest::testBiblioDeleteOrphanKeywords in tests/keyword.test
BiblioKeywordUnitTest::testBiblioGetKeywordById in tests/keyword.test
BiblioKeywordUnitTest::testBiblioGetKeywordByName in tests/keyword.test
BiblioKeywordUnitTest::testBiblioSaveKeyword in tests/keyword.test

... See full list

File

tests/keyword.test, line 21
Tests for keyword functions.

Class

BiblioKeywordWebTestCase
Class with common helper methods.

Code

function createKeyword() {
  $keyword = array();
  $keyword['word'] = $this
    ->randomName();
  biblio_save_keyword($keyword);
  $this->kids[] = $keyword['kid'];
  return $keyword;
}