Browse Source

tempalte strings & bugfixes

master
peter 4 years ago
parent
commit
fa45dc6b4f
3 changed files with 1128 additions and 53 deletions
  1. 1122
    48
      package-lock.json
  2. 2
    1
      package.json
  3. 4
    4
      test/Test.ts

+ 1122
- 48
package-lock.json
File diff suppressed because it is too large
View File


+ 2
- 1
package.json View File

1
 {
1
 {
2
   "name": "rpclibrary",
2
   "name": "rpclibrary",
3
-  "version": "1.6.1",
3
+  "version": "1.6.2",
4
   "description": "rpclibrary is a websocket on steroids!",
4
   "description": "rpclibrary is a websocket on steroids!",
5
   "main": "./js/Index.js",
5
   "main": "./js/Index.js",
6
   "repository": {
6
   "repository": {
39
     "@types/mocha": "^5.2.7",
39
     "@types/mocha": "^5.2.7",
40
     "@types/node": "^11.13.19",
40
     "@types/node": "^11.13.19",
41
     "mocha": "^6.2.0",
41
     "mocha": "^6.2.0",
42
+    "nyc": "^15.0.0",
42
     "ts-loader": "^5.3.3",
43
     "ts-loader": "^5.3.3",
43
     "ts-mocha": "^6.0.0",
44
     "ts-mocha": "^6.0.0",
44
     "typedoc": "^0.15.0",
45
     "typedoc": "^0.15.0",

+ 4
- 4
test/Test.ts View File

8
 const add = (...args:number[]) => {return args.reduce((a,b)=>a+b, 0)}
8
 const add = (...args:number[]) => {return args.reduce((a,b)=>a+b, 0)}
9
 function makeServer(){
9
 function makeServer(){
10
     let subcallback
10
     let subcallback
11
-    return new RPCServer<{ topic: string }>(21000, [{
11
+    return new RPCServer<{ topic: string }>(21010, [{
12
         name: "test",
12
         name: "test",
13
         exportRPCs: () => [
13
         exportRPCs: () => [
14
             {
14
             {
109
 
109
 
110
     before(async() => {
110
     before(async() => {
111
         server = makeServer()
111
         server = makeServer()
112
-        client = new RPCSocket(21000, "localhost")
112
+        client = new RPCSocket(21010, "localhost")
113
         return await client.connect()
113
         return await client.connect()
114
     })
114
     })
115
 
115
 
178
     let server: RPCServer<{topic: string}> 
178
     let server: RPCServer<{topic: string}> 
179
 
179
 
180
     before(async() => {
180
     before(async() => {
181
-        server = new RPCServer<{ topic: string }>(21000, [{
181
+        server = new RPCServer<{ topic: string }>(21010, [{
182
             name: "test",
182
             name: "test",
183
             exportRPCs: () => [{
183
             exportRPCs: () => [{
184
                 name: 'subscribe',
184
                 name: 'subscribe',
199
             closeHandler: (socket) => { },
199
             closeHandler: (socket) => { },
200
             errorHandler: (socket, err) => { throw err }
200
             errorHandler: (socket, err) => { throw err }
201
         })
201
         })
202
-        client = new RPCSocket(21000, "localhost")
202
+        client = new RPCSocket(21010, "localhost")
203
         return await client.connect()
203
         return await client.connect()
204
     })
204
     })
205
 
205
 

Loading…
Cancel
Save