This is a migrated thread and some comments may be shown as answers.

Bad Class Token in Elevated mode

3 Answers 85 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Ruud
Top achievements
Rank 1
Ruud asked on 03 May 2011, 02:54 PM
Hello,

I'm currently using the trial version to investigate if we want to use JustMock as our new mocking framework.
We especially like the 'Elevated' mode where we can mock mscorlib classes, etc.

However when I try to run the justmock tests (MSTest in VS2008) the Visual Studio test runner stops and throws the following error:
"Unit Test Adapter threw exception: Bad class token.."

This is my dev setup:
Windows XP
Visual Studio 2008
.NET Framework 3.5 SP1
JustMock trial

Is there a solution for this problem? If so, please let me know asap so that I can further investigate this tool.

Thanks in advance for your help.
Ruud

3 Answers, 1 is accepted

Sort by
0
Ricky
Telerik team
answered on 04 May 2011, 09:01 AM
Hello Ruud,

Thanks again for sending the issue. In order to reproduce the problem will it be possible to send us the class or reference of the framework member that you are trying to mock which is actually throwing the exception.

Kind Regards,
Ricky
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Ruud
Top achievements
Rank 1
answered on 04 May 2011, 01:14 PM
Hello Ricky,

Thanks for your quick reply!
I found the problem was running JustMock and TypeMock next to each other for my evaluation. Both applications conflict with each other if they are both running in elevation mode.
Turning off TypeMock was the solution.

Ruud
0
Ricky
Telerik team
answered on 05 May 2011, 08:31 AM
Hi Ruud,
It's great that you found the solution. Also, since Typemock and JustMock both uses profiler. Therefore, due to the overriding nature of .net profiler the first one should be turned off anyway to make JustMock elevated mode work.

Kind Regards,
Ricky
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
Ruud
Top achievements
Rank 1
Answers by
Ricky
Telerik team
Ruud
Top achievements
Rank 1
Share this question
or