diff options
Diffstat (limited to 'server/Test/AppTestClass.php')
| -rwxr-xr-x | server/Test/AppTestClass.php | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/server/Test/AppTestClass.php b/server/Test/AppTestClass.php index 4d7cab5..e1631c5 100755 --- a/server/Test/AppTestClass.php +++ b/server/Test/AppTestClass.php @@ -1,6 +1,12 @@ <?php
include_once("../core/Plugin_Api.php");
include_once("../core/LibOverride/genTokenOptions.php");
+include_once("../core/ErrorManagement.php");
+
+use OpenCloud\Common\Error\BadResponseError;
+use OpenCloud\Common\Error\BaseError;
+use OpenCloud\Common\Error\NotImplementedError;
+use OpenCloud\Common\Error\UserInputError;
class AppTest{
@@ -10,6 +16,7 @@ class AppTest{ protected $tokenClass;
protected $tokenPost;
protected $output;
+ protected $errorClass;
public function __construct($args){
@@ -19,6 +26,9 @@ class AppTest{ $this->pluginsApi = plugin_api::getInstance();
$this->errorClass = new errorManagement($this);
$this->output = array();
+
+ $this->errorClass = new errorManagement($this);
+
$this->postParams = $_POST;
}
@@ -79,10 +89,16 @@ class AppTest{ }
public function getPostParam($name){
-
+
return $this->postParams[$name];
}
+
+ public function setPostParam($name, $value){
+
+ $this->postParams[$name] = $value;
+
+ }
public function setOutput($key, $out){
@@ -94,4 +110,12 @@ class AppTest{ return json_encode($this->output);
}
+
+ public function getErrorInstance(){
+
+ return $this->errorClass;
+
+ }
}
+
+
|
