public void AddQuestionName_ShouldShouldAddQuestionNameValidNameIsGiven() { var typeEnv = new QuestionEnvironment(); var questionName = "HeyWorld!"; typeEnv.AddQuestionIdentifier(questionName); Assert.True(typeEnv.IsIdentifierDuplicate(questionName)); }
public void AddQuestionLabel_ShouldShouldAddQuestionLabelValidNameIsGiven() { var typeEnv = new QuestionEnvironment(); var questionLabel = "HeyWorld!"; typeEnv.AddQuestionLabel(new StringValue(questionLabel)); Assert.True(typeEnv.IsLabelDuplicate(new StringValue(questionLabel))); }
public void IsLableDuplicate_ShouldThrowExceptionIfInvalidNameIsGiven(string questionLabel) { var typeEnv = new QuestionEnvironment(); Assert.Throws <ArgumentException>(() => typeEnv.IsLabelDuplicate(new StringValue(questionLabel))); }
public void AddQuestionName_ShouldThrowExceptionIfInvalidNameIsGiven(string questionName) { var typeEnv = new QuestionEnvironment(); Assert.Throws <ArgumentException>(() => typeEnv.AddQuestionIdentifier(questionName)); }