The invention discloses a method and a system of electronic control unit (ECU) hardware-in-loop simulation automated testing. The method comprises the following steps: a test form is filled in so that one or a plurality of test form cases, an automation code is run to enable the form test cases to generate executable files for testing, the test is executed, and a test report is generated. An automated interpreter code is needed to design only once and is permanently effective, and an automated testing development engineer is enabled to be out of a lot of test case code translation work. By adoption of a form test case development mode, the method and the system of ECU hardware-in-loop simulation automated testing are simple, efficient, universal and flexible, and cost performance is high and practical. After a lot of form tests are developed by a testing project, corresponding executable test cases are generated by queue with one key and are automatically executed with one key, so that hardware-in-loop (HIL) automated testing of the ECU is achieved in the real sense.