public override bool CanReadType(Type type) { return type == typeof(string); }
public void TextMediaTypeFormatter_ReadsTypesTextAndNotOtherTypes() { var mediaTypeFormatter = new TextMediaTypeFormatter(); Assert.True(mediaTypeFormatter.CanReadType(typeof(string))); Assert.False(mediaTypeFormatter.CanReadType(typeof(int))); }