Created
October 13, 2011 02:05
-
-
Save anonymous/1283162 to your computer and use it in GitHub Desktop.
Good test/ bad test?
This file contains 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 GetContextId_OnSecondRun_ShouldReturnStoredContextId() | |
{ | |
const string firstContextId = "200"; | |
const string secondContextId = "400"; | |
var contextRecord = new ContextRecord(); | |
fakeRecordGenerator.GeneratRecord().Returns(contextRecord); | |
fakeContextService.CreateContextRecord(contextRecord).Returns(firstContextId); | |
contextManager.GetContextId(); | |
fakeContextService.CreateContextRecord(contextRecord).Returns(secondContextId); | |
var resultContextId = contextManager.GetContextId(); | |
Assert.AreEqual(firstContextId, resultContextId); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment