Permalink
Browse files

All tests executing without fatals under hhvm

  • Loading branch information...
1 parent 42a60c8 commit 1ad430464e3f6a4871d6d1bfefb30711bc196e93 @lorenzo lorenzo committed Feb 13, 2014
View
@@ -40,7 +40,7 @@ before_script:
- set +H
script:
- - sh -c "if [ '$PHPCS' != '1' ] && [ '$HHVM' != '1' ]; then phpunit --stderr; elif [ '$PHPCS' != '1' ] && [ '$HHVM' = '1' ]; then phpunit --testsuite HHVM; else phpcs -p --extensions=php --standard=CakePHP ./src ./tests; fi"
+ - sh -c "if [ '$PHPCS' != '1' ]; then phpunit --stderr; else phpcs -p --extensions=php --standard=CakePHP ./src ./tests; fi"
notifications:
email: false
View
@@ -23,18 +23,6 @@
<testsuite name="Database Test Suite">
<file>./tests/TestCase/DatabaseSuite.php</file>
</testsuite>
- <testsuite name="HHVM">
- <file>./tests/TestCase/DatabaseSuite.php</file>
- <directory>./tests/TestCase/Collection</directory>
- <directory>./tests/TestCase/Configure</directory>
- <directory>./tests/TestCase/Controller</directory>
- <directory>./tests/TestCase/Event</directory>
- <directory>./tests/TestCase/I18n</directory>
- <directory>./tests/TestCase/Log</directory>
- <directory>./tests/TestCase/Routing</directory>
- <directory>./tests/TestCase/TestSuite</directory>
- <directory>./tests/TestCase/Validation</directory>
- </testsuite>
</testsuites>
<listeners>
<listener class="\Cake\TestSuite\Fixture\FixtureInjector" file="./src/TestSuite/Fixture/FixtureInjector.php">
@@ -73,7 +73,7 @@ public function testEeach() {
* @return void
*/
public function testFilterChaining() {
- $this->skipIf(defined('HHVM_VERSION'), 'Broken on HHVM');
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$items = ['a' => 1, 'b' => 2, 'c' => 3];
$collection = new Collection($items);
$callable = $this->getMock('stdClass', ['__invoke']);
@@ -94,7 +94,7 @@ public function testFilterChaining() {
* @return void
*/
public function testReject() {
- $this->skipIf(defined('HHVM_VERSION'), 'Broken on HHVM');
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$items = ['a' => 1, 'b' => 2, 'c' => 3];
$collection = new Collection($items);
$result = $collection->reject(function ($v, $k, $items) use ($collection) {
@@ -545,7 +545,7 @@ public function testTake() {
* @return void
*/
public function testMatch() {
- $this->skipIf(defined('HHVM_VERSION'), 'Broken on HHVM');
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$items = [
['id' => 1, 'name' => 'foo', 'thing' => ['parent_id' => 10]],
['id' => 2, 'name' => 'bar', 'thing' => ['parent_id' => 11]],
@@ -574,7 +574,7 @@ public function testMatch() {
* @return void
*/
public function testFirstMatch() {
- $this->skipIf(defined('HHVM_VERSION'), 'Broken on HHVM');
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$items = [
['id' => 1, 'name' => 'foo', 'thing' => ['parent_id' => 10]],
['id' => 2, 'name' => 'bar', 'thing' => ['parent_id' => 11]],
@@ -29,7 +29,7 @@ class FilterIteratorTest extends TestCase {
* @return void
*/
public function testFilter() {
- $this->skipIf(defined('HHVM_VERSION'), 'Broken on HHVM');
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$items = new \ArrayIterator([1, 2, 3]);
$callable = $this->getMock('stdClass', ['__invoke']);
$callable->expects($this->at(0))
@@ -257,6 +257,7 @@ public function testEnableCryptoSocketExceptionNoSsl() {
* @return void
*/
public function testEnableCryptoSocketExceptionNoTls() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
$configNoSslOrTls = array('host' => 'localhost', 'port' => 80, 'timeout' => 0.1);
// testing exception on no ssl socket server for ssl and tls methods
@@ -288,6 +289,7 @@ protected function _connectSocketToSslTls() {
* @return void
*/
public function testEnableCryptoBadMode() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
// testing wrong encryption mode
$this->_connectSocketToSslTls();
$this->Socket->enableCrypto('doesntExistMode', 'server');
@@ -300,6 +302,7 @@ public function testEnableCryptoBadMode() {
* @return void
*/
public function testEnableCrypto() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
// testing on ssl server
$this->_connectSocketToSslTls();
$this->assertTrue($this->Socket->enableCrypto('sslv3', 'client'));
@@ -318,6 +321,7 @@ public function testEnableCrypto() {
* @return void
*/
public function testEnableCryptoExceptionEnableTwice() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
// testing on tls server
$this->_connectSocketToSslTls();
$this->Socket->enableCrypto('tls', 'client');
@@ -331,6 +335,7 @@ public function testEnableCryptoExceptionEnableTwice() {
* @return void
*/
public function testEnableCryptoExceptionDisableTwice() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
// testing on tls server
$this->_connectSocketToSslTls();
$this->Socket->enableCrypto('tls', 'client', false);
@@ -342,6 +347,7 @@ public function testEnableCryptoExceptionDisableTwice() {
* @return void
*/
public function testEnableCryptoEnableStatus() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Broken on HHVM');
// testing on tls server
$this->_connectSocketToSslTls();
$this->assertFalse($this->Socket->encrypted);
@@ -47,6 +47,7 @@ class XmlTest extends TestCase {
* @return void
*/
public function setUp() {
+ $this->assertFalse(defined('HHVM_VERSION'), 'Causes segfault on HHVM');
parent::setUp();
$this->_appEncoding = Configure::read('App.encoding');
Configure::write('App.encoding', 'UTF-8');

0 comments on commit 1ad4304

Please sign in to comment.