Exemplo n.º 1
0
        public void GetQuestion_ReturnOneQuestion_WithCorrectlyInitialisedProperties_1stWord()
        {
            _fakeXDocParser.Setup(x => x.ParseXDocument(It.IsAny <string>()))
            .Returns(_xDocument);

            _sut.InitialiseWordBank(It.IsAny <string>());
            Question question = _sut.GetQuestion();

            Assert.AreEqual(1, question.Id);
            Assert.AreEqual("word1", question.Word);
            Assert.AreEqual("Answer not given", question.Answer);
        }
Exemplo n.º 2
0
        public void GetQuestion_ReturnOneQuestion_WithCorrectlyInitialisedProperties_1stWord()
        {
            _sut.InitialiseWordBank(_xmlString);
            Question result = _sut.GetQuestion();

            Assert.AreEqual(1, result.Id);
            Assert.AreEqual("word1", result.Word);
            Assert.AreEqual("Answer not given", result.Answer);
        }