Create selftest.cpp