public void TestSingleFamily() { #if !DEBUG Assert.Multiple(() => { #endif var assert = new TypeAssert<SingleFamily>(); assert.Extends<Home>(); assert.NotImplements<IRental>(); assert.Property<string>( "Address", BindingFlags.Instance | BindingFlags.Public | BindingFlags.GetProperty ).DeclaredIn<Home>(); assert.Property<int>( "YearBuilt", BindingFlags.Public | BindingFlags.Instance | BindingFlags.GetProperty ).DeclaredIn<Home>(); assert.Property<decimal>( "Price", BindingFlags.Public | BindingFlags.Instance | BindingFlags.GetProperty ).DeclaredIn<Home>(); assert.Constructor( BindingFlags.Public | BindingFlags.Instance, new Param<string>("address"), new Param<int>("yearBuilt"), new Param<decimal>("price") ); assert.NonConstructor( BindingFlags.Public | BindingFlags.Instance ); assert.Property<decimal>( "TotalCost", BindingFlags.Public | BindingFlags.Instance | BindingFlags.GetProperty ).DeclaredIn<Home>().Override(); assert.Method<decimal>( "GetRate", BindingFlags.Public | BindingFlags.Instance, new Param<int>("numberOfPeriods") ).DeclaredIn<SingleFamily>().Override(); assert.Method<string>( "ToString", BindingFlags.Public | BindingFlags.Instance ).DeclaredIn<SingleFamily>().Override(); #if !DEBUG }); #endif }