new readme and some small fixes
This commit is contained in:
+5
-5
@@ -330,7 +330,7 @@ describe('Sesame should unlock the socket', () => {
|
||||
|
||||
it('should not work without sesame', (done) => {
|
||||
const sock = new RPCSocket(21004, "localhost")
|
||||
sock.connect<SesameTestIfc>( /* no sesame */).then(async (cli) => {
|
||||
sock.connect( /* no sesame */).then(async (cli) => {
|
||||
if (!cli.test)
|
||||
done()
|
||||
else {
|
||||
@@ -343,7 +343,7 @@ describe('Sesame should unlock the socket', () => {
|
||||
|
||||
it('should fail with wrong sesame', (done) => {
|
||||
const sock = new RPCSocket(21004, "localhost")
|
||||
sock.connect<SesameTestIfc>('abasd').then(async (cli) => {
|
||||
sock.connect('abasd').then(async (cli) => {
|
||||
if (!cli.test)
|
||||
done()
|
||||
else {
|
||||
@@ -586,8 +586,8 @@ describe("Class binding", () => {
|
||||
})
|
||||
|
||||
beforeEach((done) => {
|
||||
const s = new RPCSocket(21004, 'localhost')
|
||||
s.connect<myExporterIfc>("xxx").then(conn => {
|
||||
const s = new RPCSocket<myExporterIfc>(21004, 'localhost')
|
||||
s.connect("xxx").then(conn => {
|
||||
sock = conn
|
||||
done()
|
||||
})
|
||||
@@ -645,7 +645,7 @@ describe("Class binding", () => {
|
||||
|
||||
describe("attaching handlers before connecting", () => {
|
||||
it("fires error if server is unreachable", (done) => {
|
||||
const sock = new RPCSocket(21004, 'localhost')
|
||||
const sock = new RPCSocket<myExporterIfc>(21004, 'localhost')
|
||||
let errorHandleCount = 0
|
||||
|
||||
sock.on('error', (err) => {
|
||||
|
||||
Reference in New Issue
Block a user