public void ReturnNullIfSerializingNull()
        {
            Serializer <TimeSpan?> serializer = new NullableTimeSpanSerializer();

            byte[] actualSerializedValue = serializer.Serialize(null);

            Assert.Null(actualSerializedValue);
        }
        public void SerializeAndDeserializeToTheSameObject(TimeSpan?originalValue)
        {
            Serializer <TimeSpan?> serializer = new NullableTimeSpanSerializer();

            byte[]   serializedValue   = serializer.Serialize(originalValue);
            TimeSpan?deserializedValue = serializer.Deserialize(serializedValue);

            Assert.Equal(originalValue, deserializedValue);
        }