Stubbing Different Library Functions on Test Case by Test Case Basis
The library stubs feature is for _all_ the library functions that you might want "stubbed" in test cases in your environment. If the library functions are reference in your unit under test, then by default it will be stubbed in all test cases for functions in that unit.
If you would like a library function to be stubbed on a test case by test case basis, what you can do is use User Globals user code to create a global variable for each stub to control whether the real function is called or whether the stub code is used.
VCAST_USER_GLOBALS_EXTERN int VCAST_STUB_LIBFUNC1;
VCAST_USER_GLOBALS_EXTERN int VCAST_STUB_LIBFUNC2;
extern prototype for libfunc1(...);
if ( VCAST_STUB_LIBFUNC1 == 0 )