Convert() public method

public Convert ( object value, Type targetType, object parameter, CultureInfo culture ) : object
value object
targetType System.Type
parameter object
culture System.Globalization.CultureInfo
return object
        public void DateTimeToStringConverter_Convert_ValueNotDateTime_NoStringReturned()
        {
            //------------Setup for test--------------------------
            var dateTimeToStringConverter = new DateTimeToStringConverter();

            //------------Execute Test---------------------------
            var convertedValue = dateTimeToStringConverter.Convert("some data", null, null, null);
            //------------Assert Results-------------------------
            Assert.IsNotInstanceOfType(convertedValue, typeof(string));
        }
 public void DateTimeToStringConverter_Convert_HasDateTimeValue_StringWithSplitSeconds()
 {
     //------------Setup for test--------------------------
     var dateTimeToStringConverter = new DateTimeToStringConverter();
     var dateTimeToConvert = new DateTime(2014, 01, 02, 10, 15, 52, 52);
     //------------Execute Test---------------------------
     var convertedValue = dateTimeToStringConverter.Convert(dateTimeToConvert, null, null, null);
     //------------Assert Results-------------------------
     Assert.AreEqual("2014/01/02 10:15:52.0520 AM", convertedValue);
 }
 public void DateTimeToStringConverter_Convert_HasFormat_StringUsingProvidedFormat()
 {
     //------------Setup for test--------------------------
     var dateTimeToStringConverter = new DateTimeToStringConverter();
     dateTimeToStringConverter.Format = "dd/MMM/yyyy";
     var dateTimeToConvert = new DateTime(2014, 01, 02, 10, 15, 52, 52);
     //------------Execute Test---------------------------
     var convertedValue = dateTimeToStringConverter.Convert(dateTimeToConvert, null, null, null);
     //------------Assert Results-------------------------
     Assert.AreEqual("02/Jan/2014", convertedValue);
 }