public void CloseWindow()
        {
            TestSubject = new WindowVM();
            TestSubject.UIAccess.IsDirectAccessEnabled = true;
            TestSubject.Show();

            TestSubject.UIAccess.Window.Close();
        }
        public void Show()
        {
            TestSubject = new WindowVM();
            TestSubject.UIAccess.IsDirectAccessEnabled = true;
            TestSubject.Show();

            Assert.AreEqual(1, ApplicationVM.Current.Windows.Count);
            Assert.AreEqual(TestSubject, ApplicationVM.Current.MainWindow);

            Assert.That(TestSubject.UIAccess.HasWindow, Is.True, "HasWindow");

            //in automated unit test this will be not allays true
            Assert.That(TestSubject.UIAccess.Window.IsActive, Is.True, "Window.IsActive");

            Thread.Sleep(500);
            TestSubject.CloseAction.Execute(null);
        }