unhandled exception:objectdisposedexception
"Amrendra Shrivastava (Tata Consultancy Services)" <[email protected]>
| Newsgroups | gmane.comp.windows.dotnet.nunit.user |
|---|---|
| Message-ID | <56273ED93A85634B94F2A8998A5973CE054C262509@NA-EXMSG-C121.redmond.corp.microsoft.com> |
Hi, I am using Nunit version 2.2.8 and ran a simple Nunit test dll from the console. There were 5 failures in my tests The failures were reported correctly: Failures: 1) ReportManagement.Api.Test.Integration.CreateReportTemplateAsmxTest.CreateRepo rtTestBase.BeyondMaxValidLengthReportName : Assert: The test is supposed to fail . But it did not. at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test, TestAction cleanup) at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest, ReportSchedule repo rtSchedule, String templateName) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest) at ReportManagement.Api.Test.Integration.CreateReportTestBase.BeyondMaxValidL engthReportName() 2) ReportManagement.Api.Test.Integration.CreateReportTemplateAsmxTest.CreateRepo rtTestBase.EmptyReportName : Assert: The test is supposed to fail. But it did no t. at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test, TestAction cleanup) at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest, ReportSchedule repo rtSchedule, String templateName) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest) at ReportManagement.Api.Test.Integration.CreateReportTestBase.EmptyReportName () 3) ReportManagement.Api.Test.Integration.CreateReportTemplateAsmxTest.CreateRepo rtTestBase.NullReportName : Assert: The test is supposed to fail. But it did not . at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test, TestAction cleanup) at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteNegativeTest(TestAc tion test) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest, ReportSchedule repo rtSchedule, String templateName) at ReportManagement.Api.Test.Helper.AsmxTestHelper.NegativeTestCreateReportTe mplate(ReportManagementApi api, ReportRequest reportRequest) at ReportManagement.Api.Test.Integration.CreateReportTestBase.NullReportName( ) 4) ReportManagement.Api.Test.Integration.GetPublisherEarningsAsmxTest.GetPublish erEarnings : Assert: 2020Microsoft.AdCenter.Shared.Errors.Error-1Internal error. The operation can not be completed by backend.127686ea-9037-49f1-9975-22e9c4ec15 bf at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteTest(TestAction tes t) at ReportManagement.Api.Test.Helper.AsmxTestHelper.PositiveTestGetPublisherEa rnings(ReportManagementApi api) at ReportManagement.Api.Test.Integration.GetPublisherEarningsAsmxTest.GetPubl isherEarnings() 5) ReportManagement.Api.Test.Integration.GetReportTemplatesAsmxTest.MultipleFetc h : Assert: The feteched template is unexpected at ReportManagement.Api.Test.Helper.AsmxTestHelper.ExecuteTest(TestAction tes t) at ReportManagement.Api.Test.Helper.AsmxTestHelper.PositiveTestGetReportTempl ates(ReportManagementApi api, Int32 templateCount, Boolean needsCleanup) at ReportManagement.Api.Test.Integration.GetReportTemplatesAsmxTest.MultipleF etch() But I have received the following error in the console: Unhandled Exception: System.ObjectDisposedException: Cannot write to a closed Te xtWriter. Server stack trace: at System.IO.__Error.WriterClosed() at System.IO.StreamWriter.Flush(Boolean flushStream, Boolean flushEncoder) at System.IO.StreamWriter.Write(String value) at NUnit.ConsoleRunner.ConsoleUi.EventCollector.TestOutput(TestOutput output) at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage( IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont ext, Object[]& outArgs) at System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(R untimeMethodHandle md, Object[] args, Object server, Int32 methodPtr, Boolean fE xecuteInContext, Object[]& outArgs) at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes sage msg, Int32 methodPtr, Boolean fExecuteInContext) Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req Msg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa ta, Int32 type) at NUnit.Core.EventListener.TestOutput(TestOutput testOutput) at NUnit.Core.OutputEvent.Send(EventListener listener) at NUnit.Core.EventPump.PumpThreadProc() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, C ontextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart() Could some one explain this/solutions ?? Thanks, Amrendra ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Nunit-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nunit-users