Can I use mock objects to mock a serial port?
I am developing an application in C++/CLI that communicates with a device via a Serial Port. and testing them using MS Test. I'm just reading up about mock objects and have only understood it conceptually. I face many challeneges in unit testing, primarily because the simulator I use to send data over the serial port to my app behaves in a certain way and I cant get it to change its behaviour. What I would like to know is: Can I use mock objects to mimic the Serial Port behaviour? its input buffer? Can I use the mock object to change the Serial Port behaviour(ie to pretend that the port is