Skip to content

Commit

Permalink
Test to prove an open bug is fixed. Closes JasperFxGH-2980
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremydmiller committed Feb 21, 2024
1 parent 59448d8 commit da37afa
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions src/LinqTests/Bugs/Bug_using_literal_false_in_where_clause.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,31 @@ public async Task return_correct_results()

actual.ShouldBeEmpty();
}

[Fact]
public async Task Bug_2980()
{
var aggregate1 = new DeletableAggregate
{
Id = Guid.NewGuid(),
Deleted = true,
};
theSession.Store(aggregate1);
var aggregate2 = new DeletableAggregate
{
Id = Guid.NewGuid(),
Deleted = false,
};
theSession.Store(aggregate2);
await theSession.SaveChangesAsync();

var actual = await theSession
.Query<DeletableAggregate>()
.Where(x => false)
.ToListAsync();

actual.ShouldBeEmpty();
}
}

public class DeletableAggregate: ISoftDeleted
Expand Down

0 comments on commit da37afa

Please sign in to comment.