當前位置: 首頁>>代碼示例>>C#>>正文


C# Step.LeafFor方法代碼示例

本文整理匯總了C#中StoryTeller.Domain.Step.LeafFor方法的典型用法代碼示例。如果您正苦於以下問題:C# Step.LeafFor方法的具體用法?C# Step.LeafFor怎麽用?C# Step.LeafFor使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在StoryTeller.Domain.Step的用法示例。


在下文中一共展示了Step.LeafFor方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: step_childstepsfor_is_wired_up

 public void step_childstepsfor_is_wired_up()
 {
     var step = new Step();
     var child = new Step();
     step.LeafFor("record").Add(child);
     step.LeafFor("record").AllSteps().ShouldContain(child);
     step.LeafFor("something else").AllSteps().ShouldNotContain(child);
 }
開發者ID:adymitruk,項目名稱:storyteller,代碼行數:8,代碼來源:StepTester.cs

示例2: execute_runs_the_child_steps_within_the_fixture

        public void execute_runs_the_child_steps_within_the_fixture()
        {
            string sectionName = typeof(ArithmeticFixture).GetFixtureAlias();

            Step step = new Step().WithChildren(sectionName, new Step(), new Step(), new Step());

            var context = MockRepository.GenerateMock<ITestContext>();

            new EmbeddedSectionGrammar<ArithmeticFixture>().Execute(step, context);

            context.AssertWasCalled(
                x => x.ExecuteWithFixture<ArithmeticFixture>(step.LeafFor(sectionName), step));
        }
開發者ID:ahjohannessen,項目名稱:storyteller,代碼行數:13,代碼來源:EmbeddedSectionGrammarTester.cs

示例3: SetUp

        public void SetUp()
        {
            step = new Step();
            StepLeaf leaf = step.LeafFor("record");

            leaf.Add(new Step().With("a:1,b:2"));
            leaf.Add(new Step().With("a:3,b:4"));
            leaf.Add(new Step().With("a:5,b:6"));

            inner = new RecordingGrammar();
            grammar = new TableGrammar(inner.As<IGrammarWithCells>(), "record")
                .Before(() => inner.Numbers.Add("0"))
                .After(() => inner.Numbers.Add("7"));

            grammar.LabelName = "some label";

            grammar.Execute(step);
        }
開發者ID:adymitruk,項目名稱:storyteller,代碼行數:18,代碼來源:TableGrammarTester.cs

示例4: addTest

        private void addTest(string name, Action<StepLeaf> configure)
        {
            var test = new Test(name);
            var section = new Section(typeof(SampleTableFixture).GetFixtureAlias());
            test.Add(section);
            var step = new Step("Table1");
            section.Add(step);

            var leaf = step.LeafFor("rows");
            configure(leaf);

            AddTest(name, test);
        }
開發者ID:GaryLCoxJr,項目名稱:storyteller,代碼行數:13,代碼來源:JavaScriptTestDefinitions.cs


注:本文中的StoryTeller.Domain.Step.LeafFor方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。