Reorganize a bit, add first test case.