Tests.Tests.TestKnotThreadInteraction C# (CSharp) Method

TestKnotThreadInteraction() private method

private TestKnotThreadInteraction ( ) : void
return void
        public void TestKnotThreadInteraction()
        {
            Story story = CompileString(@"
-> knot
=== knot
    <- threadB
    -> tunnel ->
    THE END
    -> END

=== tunnel
    - blah blah
    * wigwag
    - ->->

=== threadB
    *   option
    -   something
        -> DONE
");

            Assert.AreEqual("blah blah\n", story.ContinueMaximally());

            Assert.AreEqual(2, story.currentChoices.Count);
            Assert.IsTrue(story.currentChoices[0].text.Contains("option"));
            Assert.IsTrue(story.currentChoices[1].text.Contains("wigwag"));

            story.ChooseChoiceIndex(1);
            Assert.AreEqual("wigwag\n", story.Continue());
            Assert.AreEqual("THE END\n", story.Continue());
            Assert.IsFalse(story.hasError);
        }
Tests