public void Invalidate_Should_Invalidate_Template() { var target = new PageContainer() { Template = new PageContainer() }; var layer = LayerContainer.Create("Layer1", target); target.Template.Layers = target.Template.Layers.Add(layer); bool raised = false; layer.InvalidateLayer += (sender, e) => { raised = true; }; target.Invalidate(); Assert.True(raised); }