Add test generation (Fix #4)