public DecoratedGrammarFixture() { this["GoSlowly"] = new DecoratedLineGrammar(this["Go"].As<LineGrammar>()) { Suffix = " slowly" }; this["MustGoQuickly"] = new DecoratedLineGrammar(this["Go"].As<LineGrammar>()) { Prefix = "Must ", Suffix = " quickly" }; }
public DecoratedGrammarFixture() { this["GoSlowly"] = new DecoratedLineGrammar(this["Go"].As <LineGrammar>()) { Suffix = " slowly" }; this["MustGoQuickly"] = new DecoratedLineGrammar(this["Go"].As <LineGrammar>()) { Prefix = "Must ", Suffix = " quickly" }; }
public void SetUp() { stepHistory.Clear(); var simple = new ActionGrammar("Inner", () => stepHistory.Add("INNER")); grammar = new DecoratedLineGrammar(simple) { Before = (s, c) => stepHistory.Add("Before"), After = (s, c) => stepHistory.Add("After"), Prefix = "Pre ", Suffix = " Post" }; }