public void GetSomeData()
        {
            XDocument inputDocument =
                EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Input.CsProjArrangeInput.csproj");
            var target = CreateDefaultTestTarget(CsProjArrange.ArrangeOptions.CombineRootElements);

            target.Arrange(inputDocument);

            inputDocument.Save(@"CsProjArrangeExpectedCombineRootElements.csproj");
        }
        public void Arrange_when_combineRootElements_should_return_sorted_csproj()
        {
            XDocument inputDocument =
                EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Input.SortingInput.xml");
            var target = CreateDefaultTestTarget(CsProjArrange.ArrangeOptions.CombineRootElements);

            target.Arrange(inputDocument);

            // Assert
            XDocument expectedDocument = EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Expected.SortingInputCombineRootElements.xml");

            inputDocument.ToString().Should().BeEquivalentTo(expectedDocument.ToString());
        }
        public void Arrange_when_some_elements_are_not_to_be_sorted_sort_the_other_elements_csproj()
        {
            XDocument inputDocument =
                EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Input.DoNotSortInput.xml");
            var target = CreateTestTarget(null, new[] { "DoNotSort" }, null, CsProjArrange.ArrangeOptions.None);

            // Act
            target.Arrange(inputDocument);

            XDocument expectedDocument = EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Expected.DoNotSortInput.xml");

            inputDocument.ToString().Should().BeEquivalentTo(expectedDocument.ToString());
        }
        public void Arrange_when_defaults_used_should_return_expected_csproj()
        {
            XDocument inputDocument =
                EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Input.CsProjArrangeInput.csproj");
            var target = CreateDefaultTestTarget(CsProjArrange.ArrangeOptions.None);

            // Act
            target.Arrange(inputDocument);

            // Assert
            XDocument expectedDocument = EmbeddedResourceHelper.ExtractManifestResourceAsXDocument("TestData.Expected.CsProjArrangeExpectedDefault.csproj");

            inputDocument.ToString().Should().BeEquivalentTo(expectedDocument.ToString());
        }