working towards unit tests maintain flow control