示例#1
0
        public void AllTags_NoTagsInFeatureElementAndInFeature_ReturnsEmptyList()
        {
            var scenario = new JsonScenario {
                Feature = new JsonFeature()
            };

            IReadOnlyList <string> tags = scenario.AllTags();

            Assert.IsEmpty(tags);
        }
示例#2
0
        public void AllTags_TagsInFeatureElement_ReturnsTags()
        {
            var scenario = new JsonScenario
            {
                Feature = new JsonFeature(),
                Tags    = new List <string>
                {
                    "tag1",
                    "tag2"
                }
            };

            IReadOnlyList <string> tags = scenario.AllTags();

            CollectionAssert.AreEquivalent(new[] { "tag1", "tag2" }, tags);
        }
示例#3
0
        public void AllTags_TagsBothInScenarioAndInFeatureElement_ReturnsEachTagOnlyOnce()
        {
            var scenario = new JsonScenario
            {
                Feature = new JsonFeature
                {
                    Tags = new List <string>
                    {
                        "tag1"
                    }
                },
                Tags = new List <string>
                {
                    "tag1"
                }
            };

            IReadOnlyList <string> tags = scenario.AllTags();

            CollectionAssert.AreEquivalent(new[] { "tag1" }, tags);
        }