Mercurial > pub > bltoolkit
annotate UnitTests/Fluent/MockDataBase/AssertDb.cs @ 6:11b6da379593
Исправлена странная ошибка при использовании OfType<...>().Where(...)
author | cin |
---|---|
date | Mon, 05 Dec 2016 05:50:52 +0300 |
parents | f990fcb411a9 |
children |
rev | line source |
---|---|
0 | 1 using System.Linq; |
2 using Microsoft.VisualStudio.TestTools.UnitTesting; | |
3 | |
4 namespace BLToolkit.Fluent.Test.MockDataBase | |
5 { | |
6 public class AssertDb | |
7 { | |
8 private readonly MockDb _db; | |
9 | |
10 public AssertDb(MockDb db) | |
11 { | |
12 _db = db; | |
13 } | |
14 | |
15 public void AreAll(string message = null) | |
16 { | |
17 if (_db.Commands.Any(c => !c.IsUsing)) | |
18 { | |
19 Assert.Fail(message ?? "Fail all queries"); | |
20 } | |
21 } | |
22 } | |
23 } |