Fail all callbacks disconnection / error

Callback promises are resolved when their answer is received
If the websocket disconnects or fails before receives its answer,
it's promise is rejected.
Wrong password test with failure callback
Split creating the defer and returning the promise
Implement doSendAllWithCallback

doSendAllWithCallback sends all the messages of the list
and returns a promise that is resolved when all the individual
promises are resolved.

Useful for avoiding long chains of .then().then().then() ..
Send all init commands in batch