77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
-
+
|
;; S E R V E R
;;======================================================================
(test "setup for run" #t (begin (setup-for-run)
(string? (getenv "MT_RUN_AREA_HOME"))))
(test "server-register, get-best-server" #t (let ((res #f))
(open-run-close tasks:server-register tasks:open-db 1 "bob" 1234 100 'live)
(open-run-close tasks:server-register tasks:open-db 1 "bob" 1234 100 'live 'http)
(set! res (open-run-close tasks:get-best-server tasks:open-db))
(number? (cadddr res))))
(test "de-register server" #t (let ((res #f))
(open-run-close tasks:server-deregister tasks:open-db "bob" pullport: 1234)
(list? (open-run-close tasks:get-best-server tasks:open-db))))
|
103
104
105
106
107
108
109
110
111
112
113
114
115
116
|
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
|
+
+
|
(set! *runremote* zmq-socket)
(string? (car *runremote*))))
(test #f #t (let ((res (server:client-login *runremote*)))
(car res)))
(test #f #t (car (cdb:login *runremote* *toppath* *my-client-signature*)))
(exit 1)
;;======================================================================
;; C O N F I G F I L E S
;;======================================================================
(define conffile #f)
(test "Read a config" #t (hash-table? (read-config "test.config" #f #f)))
|