コード例 #1
0
        public void it_should_call_converter_provider()
        {
            Binder.GetArgumentValue(GetContext(Body, "POST", "multipart/form-data", Boundary));

            ConverterProvider.Verify(instance => instance.FindBestInputConverter(It.IsAny <Type>(), It.IsAny <IRequestInfo>(), false), Times.Once);
        }
コード例 #2
0
        public void it_should_not_call_converter_provider()
        {
            Binder.GetArgumentValue(GetContext());

            ConverterProvider.Verify(instance => instance.FindBestInputConverter(It.IsAny <Type>(), It.IsAny <IRequestInfo>(), false), Times.Never);
        }
コード例 #3
0
 public void Should_query_converter_provider_for_converter_instance()
 {
     ConverterProvider.Verify(instance => instance.FindLiteralConverter(PropertyType), Times.Once);
 }
コード例 #4
0
 public void Should_not_query_converter_provider_for_converter_instance()
 {
     ConverterProvider.Verify(instance => instance.FindLiteralConverter(It.IsAny <Type>()), Times.Never);
 }
コード例 #5
0
 public void Should_obtain_converter_capabilities()
 {
     ConverterProvider.Verify(instance => instance.FindLiteralConverter(PropertyType), Times.Once);
 }
コード例 #6
0
        public void it_should_call_converter_provider()
        {
            Binder.GetArgumentValue(GetContext(Body, "POST", "application/x-www-url-encoded"));

            ConverterProvider.Verify(instance => instance.FindBestInputConverter(It.IsAny <Type>(), It.IsAny <IRequestInfo>(), false), Times.Once);
        }