public void an_intermediate_null_value_results_in_a_null_element() { var nested = new nested(); var inlineEelement = new InlineSharpViewElement( () => Document.CreateElement <IDivElement>().If(nested.subnested.property)); inlineEelement.Prepare(); inlineEelement.ChildNodes.Count.ShouldBe(0); }
public void both_sides_of_conditionals_inside_ifs_are_propagating_null_values() { var nested = new nested(); string value = string.Empty; var inlineEelement = new InlineSharpViewElement( () => Document.CreateElement <IDivElement>().If(nested.subnested.booleanValue || false)); inlineEelement.Prepare(); inlineEelement.ChildNodes.Count.ShouldBe(0); }
/// <summary> /// Static Imports C# 6.0 /// </summary> public static void StaticImports() { int r = Math.Min(10, 11); Console.WriteLine(r); //// To Access the static method above " Static Imports" works //// https://docs.microsoft.com/en-us/dotnet/csharp/whats-new/csharp-6#using-static Console.WriteLine(Me("SH")); //// To Access the non static method you have to create object of the class Util util = new Util(); Console.WriteLine(util.MeToo("SH")); Console.ReadLine(); //// The static using directive also imports any nested types nested obj = new nested(); }
public void both_sides_of_conditionals_inside_ifs_are_propagating_null_values() { var nested = new nested(); string value = string.Empty; var inlineEelement = new InlineSharpViewElement( () => Document.CreateElement<IDivElement>().If(nested.subnested.booleanValue || false)); inlineEelement.Prepare(); inlineEelement.ChildNodes.Count.ShouldBe(0); }
public void an_intermediate_null_value_results_in_a_null_element() { var nested = new nested(); var inlineEelement = new InlineSharpViewElement( () => Document.CreateElement<IDivElement>().If(nested.subnested.property)); inlineEelement.Prepare(); inlineEelement.ChildNodes.Count.ShouldBe(0); }