Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More test cases #49

Open
totallymike opened this issue Apr 26, 2012 · 4 comments
Open

More test cases #49

totallymike opened this issue Apr 26, 2012 · 4 comments

Comments

@totallymike
Copy link
Owner

Trying to practice TDD. With new issues, test cases to demonstrate are needed. Furthermore, I need to write more test cases to prove existing functionality and locate broken edge cases.

@ghost ghost assigned totallymike Apr 26, 2012
@sigv
Copy link
Collaborator

sigv commented Apr 26, 2012

TDD looks very interesting. Seems like something worth a try.

I also believe that the current test cases should be modified to also check the real responses. With that meaning the responses the server gets back. This can be done by opening a connection/socket with the bot and emulating the server on the test module. There should be a require('ircnode').connectTest() (or similar) for this. Then the test module would send PING and the other messages.

@totallymike
Copy link
Owner Author

I know how it can be done, and am working on it currently.

@totallymike
Copy link
Owner Author

I don't much like the idea of code written purely for testing ending up in the main module. The module should be leaner than it is, in fact. My plan was to throw up a basic net socket to sling events at the bot. That's what I did.

@sigv
Copy link
Collaborator

sigv commented Apr 27, 2012

#50 is what I was implying. I was just thinking that the special connect function would connect to the localhost:12345, but that works even better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants