Add C interface and test.
Remove old file for test.