add test.c for test