better matching

This commit is contained in:
2024-08-26 12:52:55 -06:00
parent 884e465df6
commit cafe04faf6
15 changed files with 232 additions and 33 deletions

View File

@@ -97,7 +97,7 @@ Description:
Match the following terms & definitions
^statement - a single command to be executed
^ - this is the distractor
^ - this is the distractor
";
var quiz = LocalQuiz.ParseMarkdown(rawMarkdownQuiz);
@@ -127,4 +127,33 @@ Match the following terms & definitions
quizMarkdown.Should().Contain("^ statement - a single command to be executed\n^ - this is the distractor");
}
[Fact]
public void DistractorsDoNotAddDelimiterOntheEnd()
{
var rawMarkdownQuiz = @"
Name: Test Quiz
ShuffleAnswers: true
OneQuestionAtATime: false
DueAt: 2023-08-21T23:59:00
LockAt: 2023-08-21T23:59:00
AssignmentGroup: Assignments
AllowedAttempts: -1
Description:
---
Points: 2
Match up the term with the best possible answer.
^ - a variable name
^ - A reserved word with special meaning to the compiler
";
var quiz = LocalQuiz.ParseMarkdown(rawMarkdownQuiz);
var quizMarkdown = quiz.ToMarkdown();
quizMarkdown.Should().Contain(@"Match up the term with the best possible answer.
^ - a variable name
^ - A reserved word with special meaning to the compiler");
}
}