Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 Intellisense issue in macro declared class
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

mariob
Starting Member

USA
1 Posts

Posted - Nov 30 2014 :  12:47:35 PM  Show Profile  Reply with Quote
For some reason, the framework my team is using for Unit Tests requires classes and methods to be declared with a certain macro. Unfortunately, that confuses Visual Assist big time and pretty much nothing works in our UT methods (intellisense in particular, but all features that require a form of intellisense). Here is what my code looks like:

TESTCLASSEX(MyTestClass, SomeBaseClass)
{
TESTMETHOD(MyUTMethod)
{
MyObjectThatVARecognizesEverywhereElseButNotHere myObject;
myObject.SomeMethodThatNeverShowsUpBecauseVADoesntRecognizeThisObjectInHere();
}
}

Is there some sort of customization that I can do to work around the problem? I don't expect VA to recognize the UT class, etc., but at least to be able to use intellisense while coding inside the UT method.

In other words, it would be great if VA would recognize "MyObjectThatVARecognizesEverywhereElseButNotHere".

Thanks!
-Mario

sean
Whole Tomato Software

USA
2817 Posts

Posted - Dec 01 2014 :  2:07:55 PM  Show Profile  Reply with Quote
You could try creating a local va_stdafx.h as described here: http://docs.wholetomato.com/?W302

Add the following lines to the file, then rebuild the VA symbol database and restart VS.

#define TESTCLASSEX(className, baseclass) class className : public baseclass
#define TESTMETHOD(methodName) void methodName()

// include a final blank line


Any improvement with this?
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000