public void GetDestinationsReturnOneElementArrayForSingleSource() { var metadata = new ConverterMetadata { InternalDestinations = typeof(int), }; Type[] dests = metadata.GetDestinations(); Assert.That(dests.Length, Is.EqualTo(1)); Assert.That(dests[0], Is.EqualTo(typeof(int))); }
public void GetDestinationsReturnTwoElementsArrayForListOfSources() { var metadata = new ConverterMetadata { InternalDestinations = new Type[] { typeof(int), typeof(string) }, }; Type[] dests = metadata.GetDestinations(); Assert.That(dests.Length, Is.EqualTo(2)); Assert.That(dests[0], Is.EqualTo(typeof(int))); Assert.That(dests[1], Is.EqualTo(typeof(string))); }
public void GetDestinationsReturnEmptyArrayForDefaultValue() { var metadata = new ConverterMetadata(); Assert.That(metadata.GetDestinations(), Is.Empty); }