1. A computerized apparatus comprising: a processor; an interface for obtaining a test template associated with a target computerized system, the test template comprises a plurality of template instructions; a test generator configured to generate a test associated with the test template obtained by said interface, said test generator comprises: a state simulator configured to determine a state of the target computerized system associated with an execution of the test; a template instruction selector configured to select a template instruction from the test template based on the state of the target computerized system determined by said state simulator; an instruction generator configured to generate an instruction based on the state of the target computerized system and the template instruction selected by said template instruction selector, wherein the test generator further comprises an instruction verifier configured to verify that a previously generated instruction is in line with the current state of the target computerized system and with the template instruction selected by said template instruction selector.