refactor to enable doucment driven test - draft