示例#1
0
        public void ShouldCloseInvisibleKompas()
        {
            var kompasMock = new Mock <KompasObject>();

            kompasMock.Setup(mock => mock.Visible).Returns(false);
            var wrapper = new KompasWrapper();

            SetPrivateField(wrapper, "_kompas", kompasMock.Object);
            wrapper.CloseInvisible();
            kompasMock.Verify(mock => mock.Quit());
        }
示例#2
0
 private void BladeBuilderForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     _kompas.CloseInvisible();
 }