public void AddOData_Throws_NullBuilder() { // Arrange IMvcCoreBuilder builder = null; // Act & Assert ExceptionAssert.ThrowsArgumentNull(() => builder.AddOData(), "builder"); }
public void AddOData_Throws_NullBuilderWithServiceProvider() { // Arrange IMvcCoreBuilder builder = null; Action <ODataOptions, IServiceProvider> setupAction = null; // Act & Assert ExceptionAssert.ThrowsArgumentNull(() => builder.AddOData(setupAction), "builder"); }
/// <summary> /// Adds essential OData services to the specified <see cref="IMvcCoreBuilder" />. /// </summary> /// <param name="builder">The <see cref="IMvcCoreBuilder" /> to add services to.</param> /// <returns>A <see cref="IMvcCoreBuilder"/> that can be used to further configure the OData services.</returns> public static IMvcCoreBuilder AddOData(this IMvcCoreBuilder builder) { return(builder.AddOData(opt => { })); }