public void RemoveDestinationType_Should_Remove_Mappings_With_The_Given_Destination_Type() { var mappings = new ValueMappingCollection(); mappings.Add(1, "one"); mappings.Add(2, "two"); mappings.Add(true, 1); mappings.Count().Should().Be(3); mappings.RemoveDestinationType <int>(); mappings.Count().Should().Be(2); mappings.RemoveDestinationType <string>(); mappings.Count().Should().Be(0); }
public void RemoveSourceType_Should_Remove_Mappings_With_The_Given_Source_Type() { var mappings = new ValueMappingCollection(); mappings.Add(1, "one"); mappings.Add(2, "two"); mappings.Add(true, "yes"); mappings.Count().Should().Be(3); mappings.RemoveSourceType <int>(); mappings.Count().Should().Be(1); mappings.RemoveSourceType <bool>(); mappings.Count().Should().Be(0); }