public void GetFirstCalendarSection_Finds_First_Section_In_First_Level()
        {
            var input = new IReceivedEmailSection[]
            {
                new FakeReceivedEmailSection() { ContentMimeType = CalendarMimeType},
                new FakeReceivedEmailSection(),
            };
            var expected = input[0];

            var actual = EmailCalendarRequestRetriever.GetFirstCalendarSection(input);

            Assert.That(actual, Is.EqualTo(expected));
        }
        public void GetFirstCalendarSection_Finds_First_Section_In_Second_Level_Before_Next_Item_In_Top_Level()
        {
            var expected = new FakeReceivedEmailSection() { ContentMimeType = CalendarMimeType };
            var input = new IReceivedEmailSection[]
            {
                new FakeReceivedEmailSection(),
                new FakeReceivedEmailSection() {
                    ChildSections = new List<IReceivedEmailSection>()
                    {
                        expected,
                        new FakeReceivedEmailSection(),
                    },
                },
                new FakeReceivedEmailSection() { ContentMimeType = CalendarMimeType},
            };

            var actual = EmailCalendarRequestRetriever.GetFirstCalendarSection(input);

            Assert.That(actual, Is.EqualTo(expected));
        }