Re: BackgroundWorker problems
"Nassar, Anthony" <[email protected]>
| Newsgroups | gmane.comp.windows.dotnet.nunit.user |
|---|---|
| Message-ID | <[email protected]> |
Sorry to have ignored you; I've been out sick for a few days. Ian's explanation is plausible, but I played with the tests, and I don't see any evidence for it. I have the setup method bring up the form in an entirely different thread (which works), then sleep for 5 minutes, plenty of time for the background task to complete and fire WorkCompleted. It doesn't. Nor does the form's Disposed event fire. Nor does the BackgroundWorker's Disposed event fire. Nothing happens. Ron is right; some strange condition is preventing the BackgroundWorker from ever completing its trivial task. My hypothesis is also wrong, then: NUnit is not going to unload this AppDomain while the setup method is still running. Interestingly, the problem sort of goes away if you call form1.ShowDialog(), rather than Show()! I'll post my code in a separate separately. ________________________________ From: Ian Wood [mailto:[email protected]] Sent: Friday, November 16, 2007 7:02 AM To: Lisle, Ron; Nassar, Anthony; [email protected] Subject: RE: [Nunit-users] BackgroundWorker problems > Any ideas why deriving from System.Windows.Form would cause the events to stop working? Could it be due to the fact Form implements IDisposable and maybe that's getting called and it recursively disposing its components? How are you getting on with this problem? Would be interested to know how you solve it. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Nunit-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nunit-users