add basic unit testsGeneralize auth.js to prepare for __h...

 * Generalize auth.js to prepare for __heartbeat__ (issue #17).  
 * Add error message for failed bind creds (fixes #3).  
 * add travis support