remove old test files
add new test files
add new test files
add unit tests, simplify wrappers, style fixes
more macro usage and a few cleanups