3 include_once __DIR__ . '/LocalFileTestCase.php';
5 class DemoFilesTest extends PhpXmlRpc_LocalFileTestCase
7 public function setUp()
9 $this->args = argParser::getArgs();
11 $this->baseUrl = $this->args['LOCALSERVER'] . str_replace( '/demo/server/server.php', '/demo/', $this->args['URI'] );
13 $this->coverageScriptUrl = 'http://' . $this->args['LOCALSERVER'] . '/' . str_replace( '/demo/server/server.php', 'tests/phpunit_coverage.php', $this->args['URI'] );
16 public function testAgeSort()
18 $page = $this->request('client/agesort.php');
21 public function testGetStateName()
23 $page = $this->request('client/getstatename.php');
24 $page = $this->request('client/getstatename.php', 'POST', array('stateno' => '1'));
27 public function testIntrospect()
29 $page = $this->request('client/introspect.php');
32 public function testMail()
34 $page = $this->request('client/mail.php');
35 $page = $this->request('client/mail.php', 'POST', array(
45 public function testProxy()
47 $page = $this->request('client/proxy.php', 'GET', null, true);
50 public function testWhich()
52 $page = $this->request('client/which.php');
55 public function testWrap()
57 $page = $this->request('client/wrap.php');
60 public function testDiscussServer()
62 $page = $this->request('server/discuss.php');
63 $this->assertContains('<name>faultCode</name>', $page);
64 $this->assertRegexp('#<int>10(5|3)</int>#', $page);
67 public function testProxyServer()
69 $page = $this->request('server/proxy.php');
70 $this->assertContains('<name>faultCode</name>', $page);
71 $this->assertRegexp('#<int>10(5|3)</int>#', $page);