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
 Feature Requests
 Template for "Create from usage" code
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

kolobog007
Junior Member

Russia
12 Posts

Posted - Sep 10 2010 :  2:43:47 PM  Show Profile  Reply with Quote
I'm using boost.test. And my typical coding steps are:
1) Create test code
2) Build(boost.test will run test after building)
3) Fix errors and again to 1)
Something like TDD. In this case i'm writing classes interface in test module and then implement, often using refactoring Create from usage to all non existing methods and then looking to boost.test log.

But boost.test just run program, catch all exception and output exception message to log. It looks like simple compile error. But ithout debugging i cant understand where is exception occured. And it's realy annoying.

For example what i can see in error list in VS2008.
quote:
Error 1 fatal error in "read_data_without_defaults": std::exception: The method or operation is not implemented. unknown location dataparser_test


And another example when i'm using BOOST_THROW_EXCEPTION instead simple throw

quote:
Error 1 fatal error in "class SDFFieldDesc &__thiscall SDFRecord::getField(int)": std::exception: The method or operation is not implemented. c:\\users\\john\\documents\\visual studio 2008\\projects\\dataparser\\dataparser\\sdfrecord.h 46 dataparser_test


I can understand where i forgot about implementation, and double click error to open line with this problem.

How can i change default implementation code to my?

Edited by - kolobog007 on Sep 10 2010 2:44:45 PM

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Sep 13 2010 :  1:40:51 PM  Show Profile  Reply with Quote
To change default implementation

1. click on VA Options -> Advanced -> Suggestions -> Edit VA Snippets (button)
2. edit the snippet for "Refactor Create From Usage Method Body"
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