ultimix
Main Page
Data Structures
Files
Examples
File List
Globals
unit_tests.php
Go to the documentation of this file.
1
<?php
2
3
/*
4
* This source code is a part of the Ultimix Project.
5
* It is distributed under BSD license. All other third side source code (like tinyMCE) is distributed under
6
* it's own license wich could be found from the corresponding files or sources.
7
* This source code is provided "as is" without any warranties or garanties.
8
*
9
* Have a nice day!
10
*
11
* @url http://ultimix.sorceforge.net
12
*
13
* @author Alexey "gdever" Dodonov
14
*/
15
26
class
unit_tests
{
27
38
function
test_load_package
()
39
{
40
get_package
(
'content::content_controller'
,
'last'
, __FILE__ );
41
42
return
(
'TEST PASSED'
);
43
}
44
59
function
test_simple_http
()
60
{
61
try
62
{
63
$http =
get_package
(
'http'
,
'last'
, __FILE__ );
64
65
$Response = $http->http_request(
'google.com'
);
66
67
if
( strpos( $Response ,
'google'
) !==
false
)
68
{
69
return
(
'TEST PASSED'
);
70
}
71
else
72
{
73
return
(
'ERROR'
);
74
}
75
}
76
catch
( Exception $e )
77
{
78
throw
(
new
Exception( __METHOD__.
"()::"
.$e->getMessage() ) );
79
}
80
}
81
}
82
83
?>
packages
http
include
php
unit_tests.php
Generated on Fri Sep 28 2012 17:16:32 for ultimix by
1.8.1.2