public async Task CancellationTokenModelBinder_ReturnsNonEmptyResult_ForCancellationTokenType() { // Arrange var bindingContext = GetBindingContext(typeof(CancellationToken)); var binder = new CancellationTokenModelBinder(); // Act await binder.BindModelAsync(bindingContext); // Assert Assert.True(bindingContext.Result.IsModelSet); Assert.Equal(bindingContext.HttpContext.RequestAborted, bindingContext.Result.Model); }