sergi/jsftp — pull request #82 by asylumfunk (2014-02-07 00:21:28+00:00)
Title: preserve error reply codes during authentication failure

This PR updates the ```Ftp.auth``` error handling to pass along the original error response; e.g. ```530 Not logged in.```, instead of the generic ```Login not accepted"```.

Previously, a new ```Error``` object was created and passed along to the callback.

This allows for the disambiguation of authentication error replies (```500```, ```501```, ```503```, ```421```) by preserving the original reply code and text from the server.

Corresponding test cases have been included.
- Note: These two new tests set timeouts of 10000ms, because the server hangs during invalid logins. This delay is slightly longer (~5010ms) than the default test case timeout (5000ms) and would cause the tests to otherwise fail.