Add C++ code for testing