/**
* Loads self::$db if it is not loaded already.
+ * Dies if the connection could not be established.
*
* @return void
*/
/**
* Returns sql database object
*
- * @return void
+ * @return sql_db Database instance
*/
public static function getDb()
{
--- /dev/null
+<?php
+
+class FactoryTest extends TestBase
+{
+ public function testGetDb()
+ {
+ $this->assertInstanceOf(
+ 'sql_db',
+ SemanticScuttle_Service_Factory::getDb()
+ );
+ }
+}
+?>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8" ?>
-<phpunit>
+<phpunit strict="true" colors="true"
+ bootstrap="prepare.php"
+>
<filter>
- <blacklist>
- <directory suffix=".php">.</directory>
- </blacklist>
+ <whitelist addUncoveredFilesFromWhitelist="false">
+ <directory suffix=".php">../src/SemanticScuttle/</directory>
+ <directory suffix=".php">../data/templates/</directory>
+ <directory suffix=".php">../www/</directory>
+ </whitelist>
</filter>
</phpunit>
\ No newline at end of file