Testing C++ code