Skip to content

Commit

Permalink
Update libraries and fix testsuite
Browse files Browse the repository at this point in the history
  • Loading branch information
Baachi committed Feb 3, 2013
1 parent 300c67c commit 748b082
Show file tree
Hide file tree
Showing 7 changed files with 345 additions and 60 deletions.
12 changes: 8 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,17 @@

"require": {
"php": ">=5.3.2",
"kriswallsmith/buzz": "dev-master",
"doctrine/common": "dev-master",
"doctrine/mongodb-odm": "dev-master"
"doctrine/common": "2.3.*"
},
"require-dev": {
"kriswallsmith/buzz": "0.7.*",
"doctrine/mongodb": "1.0.*",
"doctrine/mongodb-odm": "1.0.*"
},
"autoload": {
"psr-0": {
"Doctrine\\Search": "lib/"
}
}
},
"minimum-stability": "dev"
}
308 changes: 308 additions & 0 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion lib/Doctrine/Search/Mapping/ClassMetadataFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ protected function getDriver()
* @param bool $rootEntityFound
* @return void
*/
protected function doLoadMetadata($class, $parent, $rootEntityFound)
protected function doLoadMetadata($class, $parent, $rootEntityFound, array $nonSuperclassParents)
{
//Manipulates $classMetadata;
$this->driver->loadMetadataForClass($class->getName(), $class);
Expand Down Expand Up @@ -146,4 +146,9 @@ protected function initializeReflection(BaseClassMetadata $class, ReflectionServ
{
// TODO: Implement initializeReflection() method.
}

protected function isEntity(BaseClassMetadata $class)
{

}
}
7 changes: 1 addition & 6 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,10 @@
>
<testsuites>
<testsuite name="Doctrine Search Test Suite">
<directory>./tests/Unit/Doctrine/Search</directory>
<directory>./tests/Doctrine/Tests/Search</directory>
</testsuite>
</testsuites>

<php>
<!-- <server name="CLOSURE_JAR" value="/path/to/google-closure/compiler.jar" /> -->
<!-- <server name="COFFEE_BIN" value="/path/to/coffee" /> -->
</php>

<filter>
<whitelist>
<directory suffix=".php">./lib/Doctrine/Search</directory>
Expand Down
18 changes: 3 additions & 15 deletions tests/Doctrine/Tests/Search/Http/Client/BuzzTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ protected function setUp()

public function testCallExistingHost()
{
$buzzResponse = $this->getMock('Buzz\\Message\\Response');
$buzzResponse = $this->getMockBuilder('Buzz\\Message\\Response')
->disableOriginalConstructor()
->getMock();

$this->browser->expects($this->once())
->method('call')
Expand All @@ -36,18 +38,4 @@ public function testCallExistingHost()
/*$this->assertContains('<html>', $response->getContent());
$this->assertTrue($response->isSuccessfull());*/
}


public function testCallNotExistingHost()
{
$this->setExpectedException('\RuntimeException');

$clientAdapter = new FileGetContentsMock();

$browser = new Browser($clientAdapter);

$client = new BuzzClient($browser, 'www.not-existing-host.de', 80);
$client->sendRequest('get');
}

}
Loading

0 comments on commit 748b082

Please sign in to comment.