comments
[plcapi.git] / tests / 5DemofilesTest.php
index 3cbb5b4..a769bf2 100644 (file)
@@ -7,13 +7,13 @@ include_once __DIR__ . '/LocalFileTestCase.php';
  */
 class DemoFilesTest extends PhpXmlRpc_LocalFileTestCase
 {
-    public function setUp()
+    public function set_up()
     {
         $this->args = argParser::getArgs();
 
-        $this->baseUrl = $this->args['LOCALSERVER'] . str_replace( '/demo/server/server.php', '/demo/', $this->args['URI'] );
+        $this->baseUrl = $this->args['HTTPSERVER'] . str_replace( '/demo/server/server.php', '/demo/', $this->args['HTTPURI'] );
 
-        $this->coverageScriptUrl = 'http://' . $this->args['LOCALSERVER'] . '/' . str_replace( '/demo/server/server.php', 'tests/phpunit_coverage.php', $this->args['URI'] );
+        $this->coverageScriptUrl = 'http://' . $this->args['HTTPSERVER'] . '/' . str_replace( '/demo/server/server.php', 'tests/phpunit_coverage.php', $this->args['HTTPURI'] );
     }
 
     public function testAgeSort()
@@ -62,15 +62,17 @@ class DemoFilesTest extends PhpXmlRpc_LocalFileTestCase
 
     public function testDiscussServer()
     {
+        /// @todo add a couple of proper xmlrpc calls, too
         $page = $this->request('server/discuss.php');
-        $this->assertContains('<name>faultCode</name>', $page);
+        $this->assertStringContainsString('<name>faultCode</name>', $page);
         $this->assertRegexp('#<int>10(5|3)</int>#', $page);
     }
 
     public function testProxyServer()
     {
+        /// @todo add a couple of proper xmlrpc calls, too
         $page = $this->request('server/proxy.php');
-        $this->assertContains('<name>faultCode</name>', $page);
+        $this->assertStringContainsString('<name>faultCode</name>', $page);
         $this->assertRegexp('#<int>10(5|3)</int>#', $page);
     }
 }