The invention discloses a method and a device for automatically testing
common object request broker architecture (CORBA) interfaces. The method comprises the following steps: searching all methods in target language class, and acquiring the information of the interfaces; generating test cases; generating test-case data; calling dynamic invocation interfaces to execute the test cases, and transferring the test-case data into call requests sent from a
client to a
server; and recording operating response results returned from the
server. The device comprises a search and acquisition module, a
test case generation module, a test-case data module and a test-case execution module, wherein the
test case generation module is connected with the search and acquisition module, the test-case data module is connected with the
test case generation module, and the test-case execution module is connected with the test-case data module. Therefore, the test case of each interface can automatically be generated, thus the difficulty of case writing is reduced and the efficiency of case maintenance is improved; and the combination testing between the interfaces can be implemented through freely constructing a test-case set.