code generation implemented
fixed the test