vapor-community / sockets

🔌 Non-blocking TCP socket layer, with event-driven server and client.
MIT License
575 stars 54 forks source link

Implementing a struct called ErrorCodes which serves as a static Dict… #54

Closed MatthiasKreileder closed 8 years ago

MatthiasKreileder commented 8 years ago

…ionary to look up corresponding error descriptions in string format to the provided error codes (Int values). Also adding tests.

czechboy0 commented 8 years ago

Great, thanks @MatthiasKreileder! 😊 We just need a couple of things to tidy up the tests.

These should make tests run on both platforms.

Regarding the feature - could you also integrate it into the Error initializer? Whenever a new error is getting created with a code, we want to supply this looked-up string as part of the error's description. I can help with that once you have the test stuff above ready.

(Just for reference: this fixes #47)

czechboy0 commented 8 years ago

Great stuff, thanks @MatthiasKreileder!