add test and cmake config.