THRIFT-2815 Support for Multiplexing Services on any Transport, Protocol and Server
Client: Haxe
Patch: Jens Geyer
This closes #262
diff --git a/lib/haxe/test/src/TestBase.hx b/lib/haxe/test/src/TestBase.hx
index 2a344d6..1232773 100644
--- a/lib/haxe/test/src/TestBase.hx
+++ b/lib/haxe/test/src/TestBase.hx
@@ -25,7 +25,6 @@
import org.apache.thrift.server.*;
import org.apache.thrift.meta_data.*;
-import thrift.test.*; // generated code
class TestBase {
@@ -33,8 +32,15 @@
// override, if necessary
}
- public static function Run() : Void {
+ public static function Run(server : Bool) : Void {
throw new AbstractMethodError();
}
+
+ public static function Expect( expr : Bool, info : String, ?pos : haxe.PosInfos) : Void {
+ if( ! expr) {
+ throw ('Test "$info" failed at '+pos.methodName+' in '+pos.fileName+':'+pos.lineNumber);
+ }
+ }
+
}
\ No newline at end of file