On Thursday, 26 June 2014 16:01:55 CEST, Karan Luthra wrote:
1. I have proposed implementing the SMTP client using Qt's state machine framework, for the SMTP interaction is very well modelled as a finite state machine. This feels quite experimental, but I haven't yet found any reason why I shouldn't use these classes to design the client. I however might have many stones unturned at this stage, and hence request comment on this design choice.

Good question. I never worked with the state machine framework.
But indeed SMTP would fit in a state machine, as far as my
knowledge goes.

2. From where should I start?
Jan suggested TDD when the proposal was written and I read articles about this practise and I am very excited to go the TDD way. Now to get even the basic thing started, there are two tasks: A) Treat the qwwsmtpclient as a blackbox, and make it use Streams::IODeviceSocket::readLine() instead of its own instance of QSslSocket's readLine(). And, B) Treat the SMTP client as a white box, and replace the internal logic with a totally new design -- the one implemented with Qt's state machine classes. I understand A will be done first, and followed by B.

That sounds ok to me.

But I don't yet have a crystal clear plan. Being honest, this is new for me (specially the TDD). I'd rather take your (mentors) help here in assigning the tasks that can get me started and have something working by the time it's end of two weeks.

An idea (which is basically your idea, if I understand it
correctly):
1) Write tests for qwwsmtpclient.
2) Create a new design for the internals of the SMTP client (I think
  this is the biggest/hardest step). Also write tests for the
  design.
3) Write the implementation.

I'm afraid I'm kicking open doors now. If I am, could you explain
a bit more what you would like to know?

3. While I do keep looking for good articles/guides, I'd be happy to know any resources that can help me with designing/writing the SMTP parts and testing them.

I don't have any other resources in mind at this moment.

Regards,
Caspar

Reply via email to