Some more app code and first test-like code