Created
January 24, 2011 13:41
-
-
Save grumpydev/793222 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [TestMethod] | |
| public void ProcessMessage_LowerPacketSequenceNumberWithDifferentHandsetUid_RaisesBothEvents() | |
| { | |
| var mockEventDispatcher = A.Fake<IDeviceEvents>(); | |
| var fakeMessage1 = new HardwareMessage(MessageType.ReportKeyValue, 0, GetButtonPressParameters(1, 2, HardwareButton.BlueCircle)); | |
| var fakeMessage2 = new HardwareMessage(MessageType.ReportKeyValue, 0, GetButtonPressParameters(2, 1, HardwareButton.BlueCircle)); | |
| _ReportKeyValueHandler.ProcessMessage(_FakeDevice, mockEventDispatcher, fakeMessage1); | |
| _ReportKeyValueHandler.ProcessMessage(_FakeDevice, mockEventDispatcher, fakeMessage2); | |
| A.CallTo(() => mockEventDispatcher.RaiseButtonPressedEvent(A<uint>.Ignored, A<HardwareButton>.Ignored)).MustHaveHappened(Repeated.Twice); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment