git://git.onelab.eu
/
plcapi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
0230be6
)
Tests
author
gggeek
<giunta.gaetano@gmail.com>
Thu, 10 Dec 2020 17:22:35 +0000
(17:22 +0000)
committer
gggeek
<giunta.gaetano@gmail.com>
Thu, 10 Dec 2020 17:22:35 +0000
(17:22 +0000)
.travis.yml
patch
|
blob
|
history
tests/1ParsingBugsTest.php
patch
|
blob
|
history
tests/3LocalhostTest.php
patch
|
blob
|
history
tests/4LocalhostMultiTest.php
patch
|
blob
|
history
tests/5DemofilesTest.php
patch
|
blob
|
history
tests/LocalFileTestCase.php
patch
|
blob
|
history
tests/parse_args.php
patch
|
blob
|
history
diff --git
a/.travis.yml
b/.travis.yml
index
e9d8fe4
..
c270357
100644
(file)
--- a/
.travis.yml
+++ b/
.travis.yml
@@
-11,7
+11,7
@@
env:
- URI=/demo/server/server.php
- HTTPSSERVER=localhost
- HTTPSURI=/demo/server/server.php
- URI=/demo/server/server.php
- HTTPSSERVER=localhost
- HTTPSURI=/demo/server/server.php
- - PROXY=localhost:8080
+ - PROXY
SERVER
=localhost:8080
# Travis currently compiles PHP with an oldish cURL/GnuTLS combination;
# to make the tests pass when Apache has a bogus SSL cert whe need the full set of options below
- HTTPSVERIFYHOST=0
# Travis currently compiles PHP with an oldish cURL/GnuTLS combination;
# to make the tests pass when Apache has a bogus SSL cert whe need the full set of options below
- HTTPSVERIFYHOST=0
diff --git
a/tests/1ParsingBugsTest.php
b/tests/1ParsingBugsTest.php
index
4a9f23a
..
09d8b2f
100644
(file)
--- a/
tests/1ParsingBugsTest.php
+++ b/
tests/1ParsingBugsTest.php
@@
-161,7
+161,7
@@
class ParsingBugsTests extends PhpXmlRpc_PolyfillTestCase
public function testI8()
{
if (PHP_INT_SIZE == 4 ) {
public function testI8()
{
if (PHP_INT_SIZE == 4 ) {
- $this->markTestSkipped('
did not find a locale which sets decimal separator to comma
');
+ $this->markTestSkipped('
Can not test i8 as php is compiled in 32 bit mode
');
return;
}
return;
}
diff --git
a/tests/3LocalhostTest.php
b/tests/3LocalhostTest.php
index
85934d4
..
9cbd1fd
100644
(file)
--- a/
tests/3LocalhostTest.php
+++ b/
tests/3LocalhostTest.php
@@
-969,7
+969,7
@@
And turned it into nylon';
new xmlrpcval('hello world', 'string'),
));
$r = $this->send($m, 0, true);
new xmlrpcval('hello world', 'string'),
));
$r = $this->send($m, 0, true);
- $this->assert
Contains
('hello world', $r->raw_data);
+ $this->assert
StringContainsString
('hello world', $r->raw_data);
}
public function testSendTwiceSameMsg()
}
public function testSendTwiceSameMsg()
diff --git
a/tests/4LocalhostMultiTest.php
b/tests/4LocalhostMultiTest.php
index
0516c30
..
317e517
100644
(file)
--- a/
tests/4LocalhostMultiTest.php
+++ b/
tests/4LocalhostMultiTest.php
@@
-103,7
+103,7
@@
class LocalhostMultiTest extends LocalhostTest
{
if ($this->args['PROXYSERVER'] == '')
{
{
if ($this->args['PROXYSERVER'] == '')
{
- $this->markTestSkipped('PROXY definition missing: cannot test proxy');
+ $this->markTestSkipped('PROXY
SERVER
definition missing: cannot test proxy');
return;
}
return;
}
@@
-204,7
+204,7
@@
class LocalhostMultiTest extends LocalhostTest
}
else if ($this->args['PROXYSERVER'] == '')
{
}
else if ($this->args['PROXYSERVER'] == '')
{
- $this->markTestSkipped('PROXY definition missing: cannot test proxy w. http 1.1');
+ $this->markTestSkipped('PROXY
SERVER
definition missing: cannot test proxy w. http 1.1');
return;
}
return;
}
@@
-281,7
+281,7
@@
class LocalhostMultiTest extends LocalhostTest
}
else if ($this->args['PROXYSERVER'] == '')
{
}
else if ($this->args['PROXYSERVER'] == '')
{
- $this->markTestSkipped('PROXY definition missing: cannot test proxy w. https');
+ $this->markTestSkipped('PROXY
SERVER
definition missing: cannot test proxy w. https');
return;
}
else if ($this->args['HTTPSSERVER'] == '')
return;
}
else if ($this->args['HTTPSSERVER'] == '')
diff --git
a/tests/5DemofilesTest.php
b/tests/5DemofilesTest.php
index
4ee62c8
..
e064add
100644
(file)
--- a/
tests/5DemofilesTest.php
+++ b/
tests/5DemofilesTest.php
@@
-63,14
+63,14
@@
class DemoFilesTest extends PhpXmlRpc_LocalFileTestCase
public function testDiscussServer()
{
$page = $this->request('server/discuss.php');
public function testDiscussServer()
{
$page = $this->request('server/discuss.php');
- $this->assert
Contains
('<name>faultCode</name>', $page);
+ $this->assert
StringContainsString
('<name>faultCode</name>', $page);
$this->assertRegexp('#<int>10(5|3)</int>#', $page);
}
public function testProxyServer()
{
$page = $this->request('server/proxy.php');
$this->assertRegexp('#<int>10(5|3)</int>#', $page);
}
public function testProxyServer()
{
$page = $this->request('server/proxy.php');
- $this->assert
Contains
('<name>faultCode</name>', $page);
+ $this->assert
StringContainsString
('<name>faultCode</name>', $page);
$this->assertRegexp('#<int>10(5|3)</int>#', $page);
}
}
$this->assertRegexp('#<int>10(5|3)</int>#', $page);
}
}
diff --git
a/tests/LocalFileTestCase.php
b/tests/LocalFileTestCase.php
index
255a87b
..
6ec48b3
100644
(file)
--- a/
tests/LocalFileTestCase.php
+++ b/
tests/LocalFileTestCase.php
@@
-75,8
+75,8
@@
abstract class PhpXmlRpc_LocalFileTestCase extends PhpXmlRpc_PolyfillTestCase
if (!$emptyPageOk) {
$this->assertNotEquals('', $page);
}
if (!$emptyPageOk) {
$this->assertNotEquals('', $page);
}
- $this->assert
NotContains
('Fatal error', $page);
- $this->assert
NotContains
('Notice:', $page);
+ $this->assert
StringNotContainsStringIgnoringCase
('Fatal error', $page);
+ $this->assert
StringNotContainsStringIgnoringCase
('Notice:', $page);
return $page;
}
return $page;
}
diff --git
a/tests/parse_args.php
b/tests/parse_args.php
index
d9b3d5a
..
4ef568d
100644
(file)
--- a/
tests/parse_args.php
+++ b/
tests/parse_args.php
@@
-21,8
+21,6
@@
class argParser
{
public static function getArgs()
{
{
public static function getArgs()
{
- global $argv;
-
$args = array(
'DEBUG' => 0,
'LOCALSERVER' => 'localhost',
$args = array(
'DEBUG' => 0,
'LOCALSERVER' => 'localhost',
@@
-32,7
+30,7
@@
class argParser
'HTTPSVERIFYHOST' => 2,
'SSLVERSION' => 0,
'PROXYSERVER' => null,
'HTTPSVERIFYHOST' => 2,
'SSLVERSION' => 0,
'PROXYSERVER' => null,
- 'NOPROXY' => false,
+
//
'NOPROXY' => false,
'LOCALPATH' => __DIR__,
);
'LOCALPATH' => __DIR__,
);
@@
-76,8
+74,8
@@
class argParser
if (isset($SSLVERSION)) {
$args['SSLVERSION'] = (int)$SSLVERSION;
}
if (isset($SSLVERSION)) {
$args['SSLVERSION'] = (int)$SSLVERSION;
}
- if (isset($PROXY)) {
- $arr = explode(':', $PROXY);
+ if (isset($PROXY
SERVER
)) {
+ $arr = explode(':', $PROXY
SERVER
);
$args['PROXYSERVER'] = $arr[0];
if (count($arr) > 1) {
$args['PROXYPORT'] = $arr[1];
$args['PROXYSERVER'] = $arr[0];
if (count($arr) > 1) {
$args['PROXYPORT'] = $arr[1];
@@
-86,9
+84,9
@@
class argParser
}
}
// used to silence testsuite warnings about proxy code not being tested
}
}
// used to silence testsuite warnings about proxy code not being tested
- if (isset($NOPROXY)) {
- $args['NOPROXY'] = true;
- }
+
//
if (isset($NOPROXY)) {
+
//
$args['NOPROXY'] = true;
+
//
}
if (!isset($URI)) {
// GUESTIMATE the url of local demo server
// play nice to php 3 and 4-5 in retrieving URL of server.php
if (!isset($URI)) {
// GUESTIMATE the url of local demo server
// play nice to php 3 and 4-5 in retrieving URL of server.php