Author: chabotc
Date: Wed Mar 25 17:34:28 2009
New Revision: 758361

URL: http://svn.apache.org/viewvc?rev=758361&view=rev
Log:
Patch by Jacky Chao Wang, Fixes a couple of test errors in:
JsMinTest,
GadgetSpecParserTest,
Input*ConverterTest,
OrganizationTest, and
RestFulCollectionTest


Modified:
    incubator/shindig/trunk/php/test/common/JsMinTest.php
    incubator/shindig/trunk/php/test/gadgets/GadgetSpecParserTest.php
    incubator/shindig/trunk/php/test/social/InputAtomConverterTest.php
    incubator/shindig/trunk/php/test/social/InputJsonConverterTest.php
    incubator/shindig/trunk/php/test/social/InputXmlConverterTest.php
    incubator/shindig/trunk/php/test/social/OrganizationTest.php
    incubator/shindig/trunk/php/test/social/RestFulCollectionTest.php

Modified: incubator/shindig/trunk/php/test/common/JsMinTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/common/JsMinTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/common/JsMinTest.php (original)
+++ incubator/shindig/trunk/php/test/common/JsMinTest.php Wed Mar 25 17:34:28 
2009
@@ -33,7 +33,7 @@
    */
   protected function setUp() {
     parent::setUp();
-    $this->JsMin = new JsMin();
+    $this->JsMin = new JsMin('');
   }
 
   /**
@@ -53,7 +53,7 @@
    * Tests JsMin->__construct()
    */
   public function test__construct() {
-    $this->JsMin->__construct();
+    $this->JsMin->__construct('');
   }
 
   /**

Modified: incubator/shindig/trunk/php/test/gadgets/GadgetSpecParserTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/gadgets/GadgetSpecParserTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/gadgets/GadgetSpecParserTest.php (original)
+++ incubator/shindig/trunk/php/test/gadgets/GadgetSpecParserTest.php Wed Mar 
25 17:34:28 2009
@@ -70,7 +70,7 @@
    */
   public function testParseExeption() {
     $this->setExpectedException('GadgetSpecException');
-    $this->assertTrue($this->GadgetSpecParser->parse('', $this->Context));
+    $this->assertTrue($this->GadgetSpecParser->parse('<', $this->Context));
   }
 
   /**

Modified: incubator/shindig/trunk/php/test/social/InputAtomConverterTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/social/InputAtomConverterTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/social/InputAtomConverterTest.php 
(original)
+++ incubator/shindig/trunk/php/test/social/InputAtomConverterTest.php Wed Mar 
25 17:34:28 2009
@@ -142,7 +142,7 @@
    * Tests InputAtomConverter->convertPeople()
    */
   public function testConvertPeople() {
-    $this->setExpectedException(Exception);
+    $this->setExpectedException('Exception');
     $this->InputAtomConverter->convertPeople('');
   }
 }

Modified: incubator/shindig/trunk/php/test/social/InputJsonConverterTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/social/InputJsonConverterTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/social/InputJsonConverterTest.php 
(original)
+++ incubator/shindig/trunk/php/test/social/InputJsonConverterTest.php Wed Mar 
25 17:34:28 2009
@@ -102,7 +102,7 @@
    * Tests InputJsonConverter->convertPeople()
    */
   public function testConvertPeople() {
-    $this->setExpectedException(Exception);
+    $this->setExpectedException('Exception');
     $this->InputJsonConverter->convertPeople();
   }
 

Modified: incubator/shindig/trunk/php/test/social/InputXmlConverterTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/social/InputXmlConverterTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/social/InputXmlConverterTest.php (original)
+++ incubator/shindig/trunk/php/test/social/InputXmlConverterTest.php Wed Mar 
25 17:34:28 2009
@@ -126,7 +126,7 @@
    * Tests InputXmlConverter->convertPeople()
    */
   public function testConvertPeople() {
-    $this->setExpectedException(Exception);
+    $this->setExpectedException('Exception');
     $this->InputXmlConverter->convertPeople('');
   }
 }
\ No newline at end of file

Modified: incubator/shindig/trunk/php/test/social/OrganizationTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/social/OrganizationTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/social/OrganizationTest.php (original)
+++ incubator/shindig/trunk/php/test/social/OrganizationTest.php Wed Mar 25 
17:34:28 2009
@@ -34,7 +34,7 @@
   protected function setUp() {
     parent::setUp();
     
-    $this->Organization = new Organization(/* parameters */);
+    $this->Organization = new Organization('NAME');
     $this->Organization->address = 'ADDRESS';
     $this->Organization->description = 'DESCRIPTION';
     $this->Organization->endDate = 'ENDDATE';

Modified: incubator/shindig/trunk/php/test/social/RestFulCollectionTest.php
URL: 
http://svn.apache.org/viewvc/incubator/shindig/trunk/php/test/social/RestFulCollectionTest.php?rev=758361&r1=758360&r2=758361&view=diff
==============================================================================
--- incubator/shindig/trunk/php/test/social/RestFulCollectionTest.php (original)
+++ incubator/shindig/trunk/php/test/social/RestFulCollectionTest.php Wed Mar 
25 17:34:28 2009
@@ -33,6 +33,7 @@
    */
   protected function setUp() {
     parent::setUp();
+    $entry = array('Entry');
     $this->RestFulCollection = new RestfulCollection($entry, 1, 1);
   }
 
@@ -53,8 +54,7 @@
    * Tests RestFulCollection->__construct()
    */
   public function test__construct() {
-    $entry = array();
-    $entry[] = "Entry";
+    $entry = array('Entry');
     $this->RestFulCollection->__construct($entry, 1, 1);
   }
 
@@ -62,8 +62,7 @@
    * Tests RestFulCollection->getEntry()
    */
   public function testGetEntry() {
-    $entry = array();
-    $entry[] = "Entry";
+    $entry = array('Entry');
     $this->RestFulCollection->setEntry($entry);
     $this->assertEquals($entry, $this->RestFulCollection->getEntry());
   }
@@ -88,8 +87,7 @@
    * Tests RestFulCollection->createFromEntry()
    */
   public function testCreateFromEntry() {
-    $entry = array();
-    $entry[] = "Entry";
+    $entry = array('Entry');
     $restFulCollection = RestFulCollection::createFromEntry($entry);
     $this->assertEquals(1, $restFulCollection->getTotalResults());
     $this->assertEquals($entry, $restFulCollection->getEntry());


Reply via email to