mirror of
https://github.com/Biarity/Sieve.git
synced 2025-07-28 05:03:22 +02:00
Tested exception handling (#7)
This commit is contained in:
@@ -309,8 +309,8 @@ namespace Sieve.Services
|
||||
}
|
||||
catch (ArgumentException) // name matched with custom method for a differnt type
|
||||
{
|
||||
var expected = typeof(TEntity);
|
||||
var actual = ((IQueryable)customMethod.ReturnParameter).ElementType;
|
||||
var expected = typeof(IQueryable<TEntity>);
|
||||
var actual = customMethod.ReturnType;
|
||||
throw new SieveIncompatibleMethodException(name, expected, actual,
|
||||
$"{name} failed. Expected a custom method for type {expected} but only found for type {actual}");
|
||||
}
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<description>
|
||||
Sieve is a simple, clean, and extensible framework for .NET Core that adds sorting, filtering, and pagination functionality out of the box. Most common use case would be for serving ASP.NET Core GET queries. Documentation available on GitHub: https://github.com/Biarity/Sieve/
|
||||
</description>
|
||||
<releaseNotes>Custom method case-insensitivity</releaseNotes>
|
||||
<releaseNotes>Custom method case-insensitivity, new custom exceptions</releaseNotes>
|
||||
<copyright>Copyright 2018</copyright>
|
||||
<tags>aspnetcore filter sort page paginate sieve search</tags>
|
||||
<dependencies>
|
||||
|
Reference in New Issue
Block a user