public void AfterTest() { windowManagementModule = null; windowMovementEventProducer = null; windowFocusEventProducer = null; windowStateChangedEventProducer = null; windowResizingEventProducer = null; container.Dispose(); container = null; hookNativeMethods = null; }
public void BeforeTest() { windowManagementModule = new WindowManagementModule(); windowFocusEventProducer = new WindowFocusEventProducer(); windowMovementEventProducer = new WindowMovementEventProducer(); windowResizingEventProducer = new WindowResizingEventProducer(); windowStateChangedEventProducer = new WindowStateChangedEventProducer(); container = new CompositionContainer(); container.ComposeExportedValue(windowFocusEventProducer); container.ComposeExportedValue(windowMovementEventProducer); container.ComposeExportedValue(windowResizingEventProducer); container.ComposeExportedValue(windowStateChangedEventProducer); container.ComposeParts(windowManagementModule); hookNativeMethods = new HookNativeMethodsMock(); hookNativeMethods.Initialize(); }