chevron-thin-right chevron-thin-left brand cancel-circle search youtube-icon google-plus-icon linkedin-icon facebook-icon twitter-icon toolbox download check linkedin phone twitter-old google-plus facebook profile-male chat calendar profile-male
Welcome to Typemock Community! Here you can ask and receive answers from other community members. If you liked or disliked an answer or thread: react with an up- or downvote.
0 votes
Hi,

I have TypeMock Isolator 7.0.7 installed with AutoRunner and TestLint (TestLint is disabled in ExtensionManager). When I enable AutoRunner and it's running in the background, I receive the error below displayed in the Output window.

I am running Win7 x64 SP1 with VisualStudio 2010 SP1 (run as Administrator).
START: Scan
END  : 00:00:00.2492247
START: Analyzing test projects
END  : 00:00:01.2671211
START: Loading solution tests information
END  : 00:00:00.0169343
START: UpdateAssembliesWhiteList
END  : 00:00:00.0503583
START: GetAllTests
END  : 00:00:00.0000150
START: Executing tests
Failed killing daemon: System.ComponentModel.Win32Exception (0x80004005): Access is denied
   at System.Diagnostics.Process.Kill()
   at Typemock.Common.Core.DaemonNUnitRunner.KillDaemon(Process process)
Failed killing daemon: System.ComponentModel.Win32Exception (0x80004005): Access is denied
   at System.Diagnostics.Process.Kill()
   at Typemock.Common.Core.DaemonNUnitRunner.KillDaemon(Process process)
Test run failed more than 1 times - aborting
Test run failed more than 1 times - aborting
System.ServiceModel.CommunicationException: There was an error reading from the pipe: The pipe has been ended. (109, 0x6d). ---> System.IO.PipeException: There was an error reading from the pipe: The pipe has been ended. (109, 0x6d).
   at System.ServiceModel.Channels.PipeConnection.FinishSyncRead(Boolean traceExceptionsAsErrors)
   at System.ServiceModel.Channels.PipeConnection.Read(Byte[] buffer, Int32 offset, Int32 size, TimeSpan timeout)
   --- End of inner exception stack trace ---

Server stack trace: 
   at System.ServiceModel.Channels.PipeConnection.Read(Byte[] buffer, Int32 offset, Int32 size, TimeSpan timeout)
   at System.ServiceModel.Channels.DelegatingConnection.Read(Byte[] buffer, Int32 offset, Int32 size, TimeSpan timeout)
   at System.ServiceModel.Channels.SessionConnectionReader.Receive(TimeSpan timeout)
   at System.ServiceModel.Channels.SynchronizedMessageSource.Receive(TimeSpan timeout)
   at System.ServiceModel.Channels.FramingDuplexSessionChannel.Receive(TimeSpan timeout)
   at System.ServiceModel.Channels.FramingDuplexSessionChannel.TryReceive(TimeSpan timeout, Message& message)
   at System.ServiceModel.Dispatcher.DuplexChannelBinder.Request(Message message, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
   at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]: 
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
   at Typemock.Common.Core.ITestRunnerService.RunTests(List`1 assemblies, List`1 testNames, String sessionID, Dictionary`2 testsOptions)
   at Typemock.Common.Core.TestRunnerServiceSynched.RunTests(List`1 assemblies, List`1 testNames, String sessionID, Dictionary`2 testsOptions)
   at Typemock.Common.Core.DaemonNUnitRunner.PerformRunTests(List`1 testsAssemblies, IEnumerable`1 testNames, Guid sessionGuid, Dictionary`2 testOptions)
   at Typemock.Common.Core.DaemonNUnitRunner.<>c__DisplayClass5.<TryRunTests>b__0()
END  : 00:01:14.3289278
START: Loading test results
END  : 00:00:00.0060379
Test run results - 
unexpected error when trying to run test: VCI.Enterprise.AccountProcessing.Tests.SilverPopHelperTest.ShouldSendEmail
unexpected error when trying to run test: VCI.Enterprise.AccountProcessing.Tests.SilverPopRepositoryWrapperTest.SendTransactEmail_Should_Not_Throw_Exception_When_UpdateType_Is_Not_Correct
unexpected error when trying to run test: VCI.Enterprise.AccountProcessing.Tests.VciCreateAccountPayoffQuoteModuleTest.CreateMessageRequestForPayoffQuote
unexpected error when trying to run test: VCI.Enterprise.AccountProcessing.Tests.VciCreateAccountPayoffQuoteModuleTest.CheckIfPayoffCreateRequestIsValid_Test
...
...
asked by dblack (8.4k points)

62 Answers

0 votes
Thanks Alex,

awaiting for your response :)

Regards,
Nilesh Singh
answered by Nilesh Singh (580 points)
0 votes
Hi Alex,

any update??

Regards,
Nilesh Singh
answered by Nilesh Singh (580 points)
0 votes
Hi Nilesh,

Please download a new installer here.
This version should resolve the MS update issue.

Looking forward to your feedback.
answered by alex (17k points)
0 votes
Hi Alex,

Thanks a lot for sharing the latest version 7.2.3.0.I have installed the latest version and tried to run automated test cases but unfortunately it is giving the same error which i had shared u earlier. please see below errors.

1. The 'Micorsoft.jet.OLEBD.40'provider is not registered on the local machine.
- Same Error is appearing on my test project but when i changed the Target Platform properties to x86 this error does not occurred on my sample project. but when same thing i had applied for my original project, still the same error appearing for me. want to know if any other customization is needed in visual studio 2010.

2. Common language runtime has detected an invalid program. - Want to know if any customization is needed for this.

Please let me know if you need more information.

Regards,
Nilesh Singh
answered by Nilesh Singh (580 points)
0 votes
Hi Nilesh,

We've since resolved this errors. What you tried was an earlier patch. Please download the latest official version from https://www.typemock.com/download. If you see issues recurring let me know.
answered by gilz (14.5k points)
0 votes
Hi,
I am Jyoti tanwar. I have newly joined this team and now i am working on typemock issue.

I am getting following exceptions after installing latest version of typemock i.e TypemockIsolatorSuite7.4.2.0 :-
1.Can not fake methods defined in mscorlib, try faking the defining type. eg. of codeline:-
var mockDataTable = Isolate.Fake.Instance<DataTable>();
Isolate.Swap.NextInstance<DataTable>().With(mockDataTable);
Isolate.WhenCalled(() => mockDataTable.Rows[0].ItemArray[0]).WillReturn(Leader);
- Getting error while retrieving values in the above line.
2."WhenCalled does not support using a property call as an argument. To fix this pass null instead of XmlNode.debuggerDisplayProxy". eg of code line where I am getting exception:-
Isolate.WhenCalled(()=>fakeXmlDocument.AppendChild(fakeXmlNode)).WillReturn(fakeXmlNode);
I passed null value but it is returning same error message.

3.Nullable object must have a value.
var xml = new XmlDocument(); - While creating new xmldocument using typemock test cases it is not getting created and throwing above exception.

could you please help me resolving these issues? Did i miss something while installing the new version of typemock? please suggest.

regards,
Jyoti Tanwar
answered by jyoti_tanwar (220 points)
0 votes
Hi,

I have downloaded and installed the latest version of Typemock (TypemockIsolatorSuite7.4.2.0). It has resolved most of the issues but still facing few issues. please find the details below.

1. Nullable object must have a value. - Isolate.WhenCalled(() => fakeNode.Attributes[string.Empty].Value).WillReturn(LoginName);
2. Can not fake methods defined in mscorlib, try faking the defining type - Isolate.WhenCalled(() => mockDataTable.Rows[0].ItemArray[0]).WillReturn(StartDate1[0]);
3. "WhenCalled does not support using a property call as an argument.
- To fix this pass null instead of XmlNode.debuggerDisplayProxy" Isolate.WhenCalled(()=>fakeXmlDocument.AppendChild(fakeXmlNode)).WillReturn(fakeXmlNode);

These methods were working with the previous version. But now with this version these are throwing the above errors.

Most of the errors are related to the XML document objects. (Action performed on xmldocument object)

Please help me Regarding this.

Thanks,

Regards,
Nilesh Singh
answered by Nilesh Singh (580 points)
0 votes
Hi Jyoti and Nilesh.

  1. There are 6 types from mscorlib that can be faked (Docs):
    DateTime
    Environment
    System.IO
    FileStream
    StreamReader
    X509Certificate
  2. What do you mean by "Typemock test cases"?
    var xml = new XmlDocument(); - While creating new xmldocument using typemock test cases.
  3. With regards to other issues(Nullable , WhenCalled), please send me an example (code + test) that reproduces the error

Looking forward to your reply.
answered by alex (17k points)
0 votes
Hi Alex,

Please find attachment for errors and code example where we are getting errors.
Below are the code lines where we are getting mentioned errors in given code in the text file.
errorline1: Isolate.WhenCalled(() => fakeNode.Attributes[string.Empty].Value).WillReturn(LoginName);

errorline2: CategoryFilter categoryFilter = Logger.GetFilter<CategoryFilter>();

errorline3: expr = nav.Compile("/Mails/SendMail2/from");
XPathNodeIterator nodeIterFrom = nav.Select(expr);


Thanks & Regards,
jyoti

Examplecode.txt
answered by jyoti_tanwar (220 points)
0 votes
Hi,

Thank you for the tests.
I'm looking into it and will update you ASAP.
answered by alex (17k points)
...