C version of the tester