Exemplo n.º 1
0
        public static void CalculateRectanglesByCoordinates_ShouldReturnIntegerResult_WhenCollectionIsNotNullHelper(IEnumerable <IEnumerable> enumerable, int expectedResult)
        {
            OrthogonalRectangles.CalculateRectanglesByCoordinates(enumerable);

            var actualResult = OrthogonalRectangles.Count;

            Assert.AreEqual(expectedResult, actualResult);
        }
Exemplo n.º 2
0
 public static void GetIntersectedCoordsCollection_ShouldReturnCollection_WhenDictionaryIsNotNullHelper <TKey, TValue>(List <List <TValue> > expectedList, IDictionary <TKey, List <TValue> > dictionary)
 {
     expectedList.Should().BeEquivalentTo(OrthogonalRectangles.GetIntersectedCoordsCollection(dictionary));
 }
Exemplo n.º 3
0
 public static void CalculateRectanglesByCoordinates_ShouldThrowException_WhenCollectionIsNullHelper()
 {
     Assert.ThrowsException <ArgumentNullException>(() => OrthogonalRectangles.CalculateRectanglesByCoordinates(null),
                                                    "Argument can not be nul");
 }
Exemplo n.º 4
0
 public static void GetIntersectedCoordsCollection_ShouldThrowException_WhenDictionaryIsNullHelper <TKey, TValue>(IDictionary <TKey, List <TValue> > dictionary)
 {
     Assert.ThrowsException <ArgumentNullException>(() => OrthogonalRectangles.GetIntersectedCoordsCollection(dictionary), "Parameter can not be null");
 }