NLite.Data.Test.NorthwindExecutionTest.TestCoalesce2 C# (CSharp) Method

TestCoalesce2() private method

private TestCoalesce2 ( ) : void
return void
        public virtual void TestCoalesce2()
        {
            var list = db.Customers.Select(c => new { City = (c.City == "London" ? null : c.City), Country = (c.CustomerID == "EASTC" ? null : c.Country) })
                         .Where(x => (x.City ?? x.Country ?? "NoCityOrCountry") == "NoCityOrCountry").ToList();
            AssertValue(1, list.Count);
            AssertValue(null, list[0].City);
            AssertValue(null, list[0].Country);
        }
NorthwindExecutionTest