A Testable Chat Client

This section explores a simple chat client app. First, a custom chat service that is used to send and receive messages is discussed. Next, you examine how to substitute types using mocking and look at mocking the chat service. You see how to test the functionality of a viewmodel without needing to create a view for it. Finally, you learn how to create coded UI tests using the UTF TestPanel in combination with the Microsoft Automation framework.

The code for this section is located in the ChatClientView and ChatClientViewModel classes in the downloadable sample code.

The chat client app relies on a chat service, represented by an IChatService interface. The IChatService specifies a method to send a message, presumably to ...

Get Windows® Phone 8 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.