Submit and vote on feature ideas.

Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

How to use Parasoft Dynamic stubs #3

Options
wsubers
wsubers Posts: 7

Hello Community,

I am a first time user of Parasoft's dynamic stubs. I am evaluating this feature as an alternate to using Google mock.

When generating stubs, does C++Test automatically generate the code inside the stub to support Dynamic Stubing or does have a human have to write the code for the dynamic stub? As an example, on https://docs.parasoft.com/display/CPPDESKE1033/Configuration+Stub+Behavior when the stub was generated for int foo(int param1, int param2);, was it automatically generated as shown in the stub definition for int CppTest_Stub_foo (int param1, int param2) or did a human write the code within the CppTest_Stub_foo function?

Tagged:

Comments

  • piotr
    piotr Posts: 36
    Options

    Hello,

    C++test will automatically generate Dynamic Stubbing code inside the stub function - allowing simple type parameters / return value to be controlled from test case(s).

    That code can be further modified be the user, e.g. to allow modifying complex type members.