diff options
author | cweiske <cweiske@b3834d28-1941-0410-a4f8-b48e95affb8f> | 2010-08-21 23:47:56 +0000 |
---|---|---|
committer | cweiske <cweiske@b3834d28-1941-0410-a4f8-b48e95affb8f> | 2010-08-21 23:47:56 +0000 |
commit | 05832245e26758d5f758038024e86f2082471a10 (patch) | |
tree | 6260e10977bb2650c9358326a2ae5521c8352640 /tests | |
parent | d80fcf8de6440fd31f16bb4106fe9e373fa40308 (diff) | |
parent | 25baf614b8b00bb39b9d35cf6ce5ce79f0954aeb (diff) | |
download | semanticscuttle-05832245e26758d5f758038024e86f2082471a10.tar.gz semanticscuttle-05832245e26758d5f758038024e86f2082471a10.tar.bz2 |
Merge branch 'pearpkg'
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@717 b3834d28-1941-0410-a4f8-b48e95affb8f
Diffstat (limited to 'tests')
-rw-r--r-- | tests/TagsCacheTest.php | 3 | ||||
-rw-r--r-- | tests/prepare.php | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/tests/TagsCacheTest.php b/tests/TagsCacheTest.php index 9097bcb..84f4ec0 100644 --- a/tests/TagsCacheTest.php +++ b/tests/TagsCacheTest.php @@ -54,9 +54,6 @@ class TagsCacheTest extends PHPUnit_Framework_TestCase protected function setUp() { - global $dbhost, $dbuser, $dbpass, $dbname, $dbport, $dbpersist, $dbtype, $tableprefix, $TEMPLATES_DIR, $debugMode; - require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php'; - $this->us =SemanticScuttle_Service_Factory::get('User'); $this->bs =SemanticScuttle_Service_Factory::get('Bookmark'); $this->bs->deleteAll(); diff --git a/tests/prepare.php b/tests/prepare.php index ce9cd1c..6afc284 100644 --- a/tests/prepare.php +++ b/tests/prepare.php @@ -19,7 +19,13 @@ $_SERVER['HTTP_HOST'] = 'http://localhost/'; define('UNIT_TEST_MODE', true); -require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php'; +if ('@data_dir@' == '@' . 'data_dir@') { + //non pear-install + require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php'; +} else { + //pear installation; files are in include path + require_once 'SemanticScuttle/header.php'; +} require_once dirname(__FILE__) . '/TestBase.php'; require_once dirname(__FILE__) . '/TestBaseApi.php'; |