JPH08106404A - Automatic driver generating device for software test - Google Patents

Automatic driver generating device for software test

Info

Publication number
JPH08106404A
JPH08106404A JP6264507A JP26450794A JPH08106404A JP H08106404 A JPH08106404 A JP H08106404A JP 6264507 A JP6264507 A JP 6264507A JP 26450794 A JP26450794 A JP 26450794A JP H08106404 A JPH08106404 A JP H08106404A
Authority
JP
Japan
Prior art keywords
test
program
driver
execution
test execution
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP6264507A
Other languages
Japanese (ja)
Inventor
Masahiro Noguchi
正浩 野口
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nippon Steel Corp
Original Assignee
Nippon Steel Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nippon Steel Corp filed Critical Nippon Steel Corp
Priority to JP6264507A priority Critical patent/JPH08106404A/en
Publication of JPH08106404A publication Critical patent/JPH08106404A/en
Pending legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)
  • Stored Programmes (AREA)

Abstract

PURPOSE: To automatically generate the test driver which can conduct a test continuously without interruption even if a module to be tested becomes abnor mal. CONSTITUTION: The automatic driver generating device for the software test consists of a module interface information input part 1 and a test driver generation part 2, and the test driver generation part 2 is provided with a driver program generation part 2a, a test execution program generation part 2b, and a program composition part 2c to generate the test driver 3 which conducts the test through two separate processes, i.e., an execution process which actually conducts the test and a driver process which confirms the end state of the process conducting the test, thereby automatically generating the test driver which can execute plural test data continuously even if the tested program becomes abnormal during the test.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明はソフトウェアテスト用ド
ライバ自動生成装置に係わり、例えば、複数のテストデ
ータを連続して自動実行するバッチ型のテストドライバ
を自動的に生成する装置に用いて好適なものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a software test driver automatic generation device, and is suitable for use, for example, in a device for automatically generating a batch type test driver that automatically executes a plurality of test data in succession. It is a thing.

【0002】[0002]

【従来の技術】従来、通常のソフトウェアモジュールテ
ストでは、モジュールをテストするためのテストドライ
バを、テスト担当者がモジュール毎に作成している。ま
た、そのテストドライバ自体のテストも必要であるの
で、テストドライバの作成には多くの労力を必要として
いた。
2. Description of the Related Art Conventionally, in a normal software module test, a tester creates a test driver for testing a module for each module. Further, since it is necessary to test the test driver itself, it takes a lot of effort to create the test driver.

【0003】これに対し、テストドライバを自動的に生
成するというアイデアも古くから存在している。例え
ば、「Automatic Software Tes
t Drivers(1978,IEEE)」の論文で
も紹介されている。
On the other hand, the idea of automatically generating a test driver has long existed. For example, "Automatic Software Tes
t Drivers (1978, IEEE) ”.

【0004】また、公開特許公報の特開平5−1433
93号公報にて提案されている「テストプログラム生成
装置」や、特開平5−19758号公報にて提案されて
いる「テストプログラム生成方式」においても、上記論
文と同様なアイデアが提案されている。
Further, Japanese Patent Laid-Open No. 5-1433 of Japanese Patent Laid-Open
In the "test program generation device" proposed in Japanese Patent Laid-Open No. 93 and the "test program generation method" proposed in Japanese Patent Laid-Open No. 5-19758, the same idea as the above paper is proposed. .

【0005】[0005]

【発明が解決しようとする課題】しかしながら、実際に
テストを実行する場合には、テスト対象モジュールの異
常により、プログラムが異常に終了してしまったり、或
いはプログラムが無限ループに陥ってしまったりする現
象が発生することがある。
However, when the test is actually executed, the program ends abnormally due to an abnormality in the module to be tested, or the program falls into an infinite loop. May occur.

【0006】このような異常な現象が発生すると、複数
のテストデータを使用してバッチ的にテスト実行を行う
ようにしていたとしても、一旦異常が発生すればテスト
自動実行が中断してしまうことがある。
When such an abnormal phenomenon occurs, even if the test execution is performed in batch using a plurality of test data, the automatic test execution will be interrupted once the abnormality occurs. There is.

【0007】従来のテストドライバ自動生成装置で生成
されるテストドライバでは、このような場合についての
配慮はなされていなかった。また、上記論文においても
このような場合の対処については述べられていなかっ
た。
In the conventional test driver generated by the automatic test driver generation device, no consideration has been given to such a case. Further, the above paper did not mention how to deal with such a case.

【0008】また、上記特開平5−143393号公報
や、特開平5−19758号公報においても異常発生時
の対処が行えるようにはなっていなかったので、テスト
対象のモジュールが異常終了したり、無限ループが発生
したりすると、テストの実行が中断してしまい、テスト
作業を効率的に行うことができなくなってしまう問題が
あった。
Also, in the above-mentioned Japanese Patent Laid-Open No. 5-143393 and Japanese Patent Laid-Open No. 5-19758, it is not possible to deal with the occurrence of an abnormality, so that the module to be tested ends abnormally, If an infinite loop occurs, the test execution will be interrupted and the test work cannot be performed efficiently.

【0009】本発明は上述の問題点にかんがみ、テスト
時にテスト対象のモジュールに異常が発生した場合に
も、テスト実行が中断されることなく連続的に行うこと
が可能なテストドライバを自動的に生成できるようにす
ることを目的とする。
In view of the above-mentioned problems, the present invention automatically provides a test driver capable of continuously performing the test execution without interruption even when an abnormality occurs in the module to be tested during the test. The purpose is to be able to generate.

【0010】[0010]

【課題を解決するための手段】本発明のソフトウェアテ
スト用ドライバ自動生成装置は、テスト対象のモジュー
ルのインタフェース情報を入力するためのインタフェー
ス情報入力部と、上記テスト対象のモジュールを実際に
実行させるテストを行うようにするテスト実行プログラ
ムを自動的に生成するテスト実行プログラム生成部と、
上記テスト実行プログラム生成部により生成されたテス
ト実行プログラムを、独立した別のプロセスとして実行
させるようにするためのドライバプログラムを自動的に
生成するドライバプログラム生成部と、上記テスト実行
プログラム生成部により生成されたテスト実行プログラ
ムと、上記ドライバプログラム生成部により生成された
ドライバプログラムとを合成してテストドライバを生成
するプログラム合成部とを具備している。
SUMMARY OF THE INVENTION A software test driver automatic generation apparatus according to the present invention includes an interface information input section for inputting interface information of a test target module, and a test for actually executing the test target module. And a test execution program generator that automatically generates a test execution program that
A driver program generation unit that automatically generates a driver program for executing the test execution program generated by the test execution program generation unit as a separate independent process, and a test execution program generation unit generated by the test execution program generation unit. The test execution program is combined with the driver program generated by the driver program generation unit to generate a test driver.

【0011】また、本発明の他の特徴とするところは、
上記テスト実行プログラム生成部は、テストデータを読
み込むためのプログラムと、上記テストを開始してから
一定時間が経過した後は上記テストを異常終了させるこ
とにより、上記テスト対象のモジュールの無限ループを
判断するようにするためのプログラムと、上記テスト対
象のモジュールに読み込んだテストデータを渡して実行
するためのプログラムと、上記テスト対象のモジュール
の実行結果を出力するためのプログラムとを生成するこ
とを特徴とする。
Another feature of the present invention is that
The test execution program generation unit determines a program for reading test data and an infinite loop of the test target module by abnormally ending the test after a certain time has passed from the start of the test. And a program for passing and executing the read test data to the test target module, and a program for outputting the execution result of the test target module. And

【0012】また、本発明のその他の特徴とするところ
は、上記ドライバプログラム生成部は、テスト実行プロ
グラムを独立した別のプロセスとして実行させるための
プログラムと、上記テスト実行プログラムを独立した別
のプロセスとして実行させた時に、そのテスト実行プロ
グラムを実行したプロセスの終了状態を検査するための
プログラムと、上記テスト実行プログラムがなんらかの
異常発生により終了していた場合に、その異常終了のテ
スト実行結果を出力するためのプログラムと、上記の処
理を行うプログラムを全てのテストデータに対して実行
させるプログラムとを生成することを特徴とする。
Another feature of the present invention is that the driver program generation unit executes a test execution program as another independent process and another test execution program as another independent process. When the program is executed as, the program for checking the end status of the process that executed the test execution program and the above test execution program that has terminated due to some abnormality output the test execution result of the abnormal termination. And a program for executing the above-described processing program on all the test data are generated.

【0013】[0013]

【作用】本発明のソフトウェアテスト用ドライバ自動生
成装置は上記技術手段よりなるので、テストを実際に実
行する実行プロセスと、そのテストを実行するプロセス
の終了状態を確認するドライバプロセスとの2つのプロ
セスに分けてテストを実行するような仕組みのテストド
ライバを生成することができるようになり、これによ
り、テスト時のテスト対象プログラムに異常が発生して
も、複数のテストデータを連続して実行することができ
るようになる。
Since the software test driver automatic generation apparatus of the present invention comprises the above technical means, it has two processes, an execution process for actually executing the test and a driver process for confirming the end state of the process for executing the test. It becomes possible to generate a test driver with a mechanism to execute the test separately, so that even if an error occurs in the test target program at the time of testing, multiple test data are executed continuously. Will be able to.

【0014】[0014]

【実施例】以下、本発明のソフトウェアテスト用ドライ
バ自動生成装置の一実施例を図面を参照して説明する。
図1は、本発明の一実施例を示し、本実施例のドライバ
自動生成装置の概略構成を示すブロック図である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of a software test driver automatic generation apparatus of the present invention will be described below with reference to the drawings.
FIG. 1 shows an embodiment of the present invention and is a block diagram showing a schematic configuration of an automatic driver generation apparatus of the present embodiment.

【0015】図1に示したように、本実施例のソフトウ
ェアテスト用ドライバ自動生成装置は、モジュールイン
タフェース情報入力部1、テストドライバ生成部2によ
り構成されていて、テスト実行時のテスト対象プログラ
ムの異常に対処することが可能な仕組みを持つテストド
ライバ3を自動的に生成することができるようになって
いる。
As shown in FIG. 1, the software test driver automatic generation apparatus of this embodiment is composed of a module interface information input section 1 and a test driver generation section 2, and is used for a test target program at the time of test execution. The test driver 3 having a mechanism capable of coping with an abnormality can be automatically generated.

【0016】本実施例のモジュールインタフェース情報
入力部1は、テスト対象のモジュールのインタフェース
情報を入力するために設けられているものである。例え
ば、テスト対象のモジュールが実装されているソースコ
ードを入力として、そのソースコードの構文解析を自動
で行い、テスト対象モジュールへの入出力変数を解析す
ることができるように構成されている。
The module interface information input section 1 of this embodiment is provided to input the interface information of the module to be tested. For example, the source code in which the module to be tested is mounted is input, the source code is automatically parsed, and the input and output variables to the module to be tested can be analyzed.

【0017】また、テストドライバ生成部2は、ドライ
バプログラム生成部2aと、テスト実行プログラム生成
部2bと、プログラム合成部2cとを有し、テストドラ
イバ3を自動生成するようになされている。
The test driver generator 2 has a driver program generator 2a, a test execution program generator 2b, and a program synthesizer 2c, and is adapted to automatically generate the test driver 3.

【0018】上記ドライバプログラム生成部2aは、図
2のブロック図に示すように、第1のドライバプログラ
ム生成手段21と、第2のドライバプログラム生成手段
22と、第3のドライバプログラム生成手段23とによ
り構成されている。
As shown in the block diagram of FIG. 2, the driver program generator 2a includes a first driver program generator 21, a second driver program generator 22, and a third driver program generator 23. It is composed by.

【0019】また、上記テスト実行プログラム生成部2
bは、読み込みプログラム生成手段11と、実行プログ
ラム生成手段12と、制限時間設定プログラム生成手段
13と、実行結果出力プログラム生成手段14とによっ
て構成されている。
Further, the test execution program generator 2
b is composed of a reading program generation means 11, an execution program generation means 12, a time limit setting program generation means 13, and an execution result output program generation means 14.

【0020】このように構成された本実施例のテストド
ライバ生成部2は、モジュールインタフェース情報入力
部1により入力された結果を基に、次のようにしてテス
トドライバを自動生成する。すなわち、図3のフローチ
ャートに示したように、処理がスタートすると、先ず、
ステップS1においてテスト対象のソースコードが供給
されると、次のステップS2においてモジュールインタ
フェース情報解析が行われる。
The test driver generation unit 2 of the present embodiment thus configured automatically generates the test driver as follows based on the result input by the module interface information input unit 1. That is, as shown in the flowchart of FIG. 3, when the process starts, first,
When the source code to be tested is supplied in step S1, module interface information analysis is performed in the next step S2.

【0021】以下、ステップS3〜ステップS10の処
理が行われるが、ステップS3〜ステップS6の処理は
テスト実行プログラム生成部2bにより行われ、ステッ
プS7〜ステップS9はドライバプログラム生成部2a
により行われ、ステップS10の処理はプログラム合成
部2cにより行われる。
Hereinafter, the processes of steps S3 to S10 are performed, but the processes of steps S3 to S6 are performed by the test execution program generation unit 2b, and steps S7 to S9 are performed by the driver program generation unit 2a.
The process of step S10 is performed by the program synthesizing unit 2c.

【0022】先ず、ステップS3においては、読み込み
プログラム生成手段11により、テストデータを読み込
むプログラムが生成される。次に、ステップS4に進
み、実行プログラム生成手段12により、テスト対象モ
ジュールを実行するプログラムが生成される。
First, in step S3, the reading program generating means 11 generates a program for reading test data. Next, in step S4, the execution program generation means 12 generates a program for executing the test target module.

【0023】また、次のステップS5において、制限時
間設定プログラム生成手段13により、テスト対象のモ
ジュールの無限ループを判断するために、一定時間後に
異常終了させるためのプログラムが生成される。これに
より、テスト対象モジュールの実行時の制限時間が設定
されるとともに、テスト対象のモジュールに読み込んだ
テストデータを渡して実行される。また、次のステップ
S6では、実行結果出力プログラム生成手段14によ
り、テスト対象のモジュールの実行結果を出力するプロ
グラム生成される。
In the next step S5, the time limit setting program generating means 13 generates a program for abnormal termination after a certain time in order to determine the infinite loop of the module to be tested. As a result, the time limit for the execution of the test target module is set, and the test data read to the test target module is passed and executed. In the next step S6, the execution result output program generation means 14 generates a program for outputting the execution result of the module to be tested.

【0024】これらのステップS3〜ステップS6の処
理により、テスト実行プログラム10が生成される。こ
のテスト実行プログラム10は、テストドライバ3のな
かで、テスト対象のモジュールを実際に呼び出してテス
トを実行させるための部分であり、一つのテストデータ
に対しての処理プログラムである。
The test execution program 10 is generated by the processing of these steps S3 to S6. The test execution program 10 is a part of the test driver 3 for actually calling a module to be tested and executing a test, and is a processing program for one test data.

【0025】次のステップS7では、第1のドライバプ
ログラム生成手段21により、テスト実行プログラムを
独立した別のプロセスとして実行させるためのプログラ
ムが生成される。
In the next step S7, the first driver program generating means 21 generates a program for executing the test execution program as another independent process.

【0026】また、ステップS8では、第2のドライバ
プログラム生成手段22により、テスト実行プログラム
を独立した別のプロセスとして実行させた時に、そのテ
スト実行プログラムを実行したプロセスの終了状態を検
査するためのプログラムが生成される。
Further, in step S8, when the second driver program generation means 22 causes the test execution program to be executed as another independent process, the end state of the process executing the test execution program is inspected. The program is generated.

【0027】さらに、ステップS9では、第3のドライ
バプログラム生成手段23により、テスト実行プログラ
ムがなんらかの異常発生により終了していた場合に、そ
の異常終了のテスト実行結果を出力するようにするとと
もに、上記の処理を行うプログラムを全てのテストデー
タに対して実行させるようにするプログラムが生成され
る。これらのステップS7〜ステップS9によりドライ
バプログラム20が生成される。このドライバプログラ
ム20は、テスト実行プログラム10を独立した別プロ
セスとして実行させることができる。
Further, in step S9, when the test execution program has ended due to some abnormality, the third driver program generation means 23 outputs the test execution result of the abnormal end, and A program that causes the program that performs the process of (1) to be executed on all test data is generated. The driver program 20 is generated by these steps S7 to S9. The driver program 20 can execute the test execution program 10 as an independent separate process.

【0028】次のステップS10においては、プログラ
ム合成部2cにより、上述したようにして生成されたテ
スト実行プログラム10と、ドライバプログラム20と
を合成してテストドライバ3が生成される。
In the next step S10, the program synthesizing unit 2c synthesizes the test execution program 10 generated as described above and the driver program 20 to generate the test driver 3.

【0029】このようにして、実際にテスト対象のモジ
ュールを実行するプロセスを独立した別のプロセスとし
て実行させるようなテストドライバ3を生成することに
より、テスト実行時のテスト対象のモジュールの異常に
対処することが可能なテストドライバ3を自動生成する
ことが可能となる。
In this way, by generating the test driver 3 which causes the process for actually executing the module to be tested to be executed as a separate independent process, the abnormality of the module to be tested during the test execution is dealt with. It becomes possible to automatically generate the test driver 3 which can be performed.

【0030】次に、本実施例のソフトウェアテスト用ド
ライバ自動生成が自動生成するテストドライバ3がどの
ように動作するかについて説明する。図4および図5
に、本実施例によるテストドライバ3のテスト作業の一
例のフローチャートを示す。上述したように、本実施例
のソフトウェアテスト用ドライバ自動生成装置により生
成されたテストドライバ3は、ドライバプログラム20
とテスト実行プログラム10とから構成される。
Next, how the test driver 3 automatically generated by the software test driver automatic generation of this embodiment operates will be described. 4 and 5
The flowchart of an example of the test work of the test driver 3 according to the present embodiment is shown in FIG. As described above, the test driver 3 generated by the software test driver automatic generation device according to the present embodiment is the driver program 20.
And a test execution program 10.

【0031】先ず、ステップS1において、テスト実行
プログラム10およびドライバプログラム20は、テス
ト対象のプログラムとリンクされ、テスト用の実行ファ
イルが作られる。
First, in step S1, the test execution program 10 and the driver program 20 are linked with the program to be tested, and a test execution file is created.

【0032】次に、ステップS2に進み、ステップS1
で作られた実行ファイルを使用してテストが実行され
る。テストが実行されると、まず、ステップS3におい
てドライバプログラム部分が実行され、ドライバプロセ
スが作られる。
Next, in step S2, step S1
The test is executed using the executable file created in. When the test is executed, first, the driver program portion is executed in step S3 to create a driver process.

【0033】これにより、ステップS4以下においてド
ライバプロセスおよびテスト実行プロセスが行われるこ
とになるが、図4および図5において、ステップS4〜
ステップS9がドライバプロセスを示し、ステップS1
0〜ステップS14がテスト実行プロセスを示してい
る。
As a result, the driver process and the test execution process are performed in and after step S4, but in FIG. 4 and FIG.
Step S9 shows the driver process, and step S1
0 to step S14 show the test execution process.

【0034】上述したように、ドライバプロセスが作ら
れると、次に、ステップS4に進み、そのドライバプロ
セスがテスト実行プロセスを生成する。そして、次のス
テップS5においてテスト実行か否かを判断し、テスト
実行の場合はステップS10に進む。
As described above, when the driver process is created, the process proceeds to step S4, and the driver process creates a test execution process. Then, in the next step S5, it is determined whether or not the test is executed, and if the test is executed, the process proceeds to step S10.

【0035】ステップS10においては、テスト対象の
プログラムへ入力されるテストデータを読み込み、その
後ステップS11に進んでテスト対象のプログラムを実
行する。
In step S10, the test data input to the test target program is read, and then the process proceeds to step S11 to execute the test target program.

【0036】次に、ステップS12において異常発生の
有無を判断し、テスト対象プログラムの実行が正常に終
了した場合には、ステップS13に進んでその結果を出
力してから、ステップS14に進んでプロセスを終了す
る。
Next, in step S12, it is judged whether or not an abnormality has occurred, and if the execution of the program under test ends normally, the process proceeds to step S13 to output the result, and then the process proceeds to step S14. To finish.

【0037】また、ステップS12の判断の結果、テス
ト実行時に異常が発生した場合には、オペレーティング
システムからの割り込み(セグメンテーションフォール
トなど)により、テスト実行プロセスが異常終了する。
また、ある一定時間を過ぎてもテスト対象プログラムの
実行が終了しない場合には、無限ループであると判断し
て、その際もテスト実行プロセスが異常終了する。
Further, as a result of the determination in step S12, if an abnormality occurs during the test execution, the test execution process abnormally ends due to an interrupt (segmentation fault or the like) from the operating system.
If the execution of the test target program does not end even after a certain period of time, it is determined to be an infinite loop, and the test execution process also abnormally ends at that time.

【0038】ドライバプロセスは、生成したテスト実行
プロセスが終了するまで待つ(ステップS6)。そし
て、ステップS7において、テスト実行プロセスの終了
状態を確認することで、テスト対象のプログラムの異常
を検出する。そして、異常が発生していれば、次のステ
ップS8において異常時の実行結果を出力する。
The driver process waits until the generated test execution process ends (step S6). Then, in step S7, the abnormal state of the program to be tested is detected by confirming the end state of the test execution process. If an abnormality has occurred, the execution result at the time of abnormality is output in the next step S8.

【0039】次に、ステップS9において全てのテスト
データを実行したか否かを判断し、次のテストデータが
あればステップS4に戻ってテスト実行プロセスを新た
に生成して、次のテストデータの実行に移る。また、全
てのテストデータの実行が終了していれば、ドライバプ
ロセス自体が終了してテストの実行を終了する。
Next, in step S9, it is determined whether or not all the test data has been executed. If there is the next test data, the process returns to step S4 to newly generate a test execution process, and the next test data Go to execution. If the execution of all the test data has been completed, the driver process itself ends and the test execution ends.

【0040】このようにして、ドライバプロセスが終了
した時点で全てのテストデータが実行される。その際
に、あるテストデータでテスト対象のモジュールを実行
中に、異常終了や無限ループのような異常が発生して
も、全てのテストデータを連続的に実行することが可能
である。
In this way, all the test data are executed when the driver process is completed. At that time, all the test data can be continuously executed even when an abnormality such as an abnormal end or an infinite loop occurs while the module to be tested is being executed with certain test data.

【0041】上述したように、本実施例のソフトウェア
テスト用ドライバ自動生成装置は、テストを実際に実行
するプロセスと、そのテストを実行するプロセスの終了
状態を確認するプロセスとの二つのプロセスに分けてテ
ストを実行するような仕組みにしているので、本実施例
のソフトウェアテスト用ドライバ自動生成装置により自
動生成されたテストドライバ3は、テスト時のテスト対
象プログラムに異常が発生しても連続して複数のテスト
データを実行することを可能としている。
As described above, the software test driver automatic generation apparatus of this embodiment is divided into two processes: a process for actually executing a test and a process for confirming the end state of the process for executing the test. The test driver 3 automatically generated by the software test driver automatic generation apparatus according to the present embodiment has a structure in which a test target program at the time of a test is abnormal. It is possible to run multiple test data.

【0042】次に、本発明の具体例として、C言語で書
かれた図6のサンプルプログラムをテストした場合の例
を示す。
Next, as a specific example of the present invention, an example in which the sample program of FIG. 6 written in C language is tested will be shown.

【0043】図6に示したように、このプログラムは、
アボートや無限ループなどの異常が発生する可能性のあ
るようなサンプルプログラムである。このサンプルプロ
グラムのソースコードを本実施例によるソフトウェアテ
スト用ドライバ自動生成装置に入力することで、モジュ
ールインタフェース情報入力部1がそのソースコードを
解析して、テストドライバ生成部2によりテスト対象モ
ジュールのテストドライバ3が自動生成される。
As shown in FIG. 6, this program
This is a sample program that may cause abnormalities such as aborts and infinite loops. By inputting the source code of this sample program into the software test driver automatic generation device according to the present embodiment, the module interface information input unit 1 analyzes the source code, and the test driver generation unit 2 tests the test target module. The driver 3 is automatically generated.

【0044】そのテストドライバ3と図6のサンプルプ
ログラムとをリンクすることにより、テスト用の実行フ
ァイルが作成される。そして、そのテスト用の実行ファ
イルに、テスト対象のプログラムの入力変数であるin
t型の変数xとstructTEST型の変数tへ入力
するテストデータを、図7のように記述したテストデー
タ記述ファイルを渡すことで、このテストデータを使用
したテストが実行される。このテストデータ記述ファイ
ルには、3つのテストデータが記述されており、各々の
テストデータにはテストデータを識別する番号が付加さ
れている。
By linking the test driver 3 with the sample program of FIG. 6, an execution file for testing is created. Then, in the execution file for the test, in which is the input variable of the program to be tested
A test using the test data is executed by passing a test data description file in which the test data to be input to the t-type variable x and the structTEST type variable t are described as shown in FIG. 7. In this test data description file, three test data are described, and a number for identifying the test data is added to each test data.

【0045】上記のテストデータによりテストが実施さ
れた結果、図8のようなテスト実行結果が各テストデー
タ毎に出力される。テスト実行結果には、テストデータ
に対応する識別番号が付加されている。
As a result of performing the test with the above test data, the test execution result as shown in FIG. 8 is output for each test data. An identification number corresponding to the test data is added to the test execution result.

【0046】図8のテスト実行結果では、1番目と3番
目のテスト結果が、テスト実行時にシグナルと呼ばれる
割り込みによってテスト実行が異常終了したことを表し
ており、そのシグナルの種類を表す番号が出力されてい
る。
In the test execution result of FIG. 8, the first and third test results show that the test execution is abnormally terminated by an interrupt called a signal during the test execution, and the number indicating the type of the signal is output. Has been done.

【0047】また、2番目のテスト結果は異常終了が発
生しなかった場合のテスト実行結果であり、テスト対象
のモジュールによる実行結果が出力されている。この例
では、1番目のテストデータの実行により異常が発生し
ているが、次のテストデータを連続して実行することが
可能となっていることが分かる。
The second test result is the test execution result when no abnormal termination occurs, and the execution result by the module to be tested is output. In this example, although the abnormality has occurred due to the execution of the first test data, it can be seen that the next test data can be continuously executed.

【0048】[0048]

【発明の効果】本発明は上述したように、本発明によれ
ば、テスト実行時に作成するテストドライバの自動生成
が可能になり、大量のモジュールから構成されるプログ
ラムのテスト時や、モジュールの仕様変更などによるテ
ストを効率的に行うことが可能となる。
As described above, according to the present invention, it is possible to automatically generate a test driver to be created at the time of executing a test, and to test a program composed of a large number of modules or to specify the module specifications. It becomes possible to efficiently perform a test due to a change or the like.

【0049】さらに、テストが異常な状態で終了した場
合にも連続してテストを実行することができるような機
能を持つ高度なテストドライバを自動生成することが可
能になるので、従来のテストドライバ自動生成装置/方
式により生成されるテストドライバと比較して、より効
率的なテスト作業を実施することができる。
Further, since it becomes possible to automatically generate an advanced test driver having a function of continuously executing a test even when the test is terminated in an abnormal state, the conventional test driver can be used. Compared with the test driver generated by the automatic generation device / method, more efficient test work can be performed.

【0050】特に、複数のテストデータを連続して自動
実行するバッチ型のテストドライバによるテストの自動
実行や縮退テストの自動実行の際に、より効果的なテス
ト作業を行うことが可能となる。
In particular, a more effective test work can be performed at the time of automatic execution of a test by a batch type test driver which automatically executes a plurality of test data continuously and automatic execution of a degenerate test.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明のソフトウェアテスト用ドライバ自動生
成装置の一実施例を示すブロック図である。
FIG. 1 is a block diagram showing an embodiment of a software test driver automatic generation device of the present invention.

【図2】テストドライバ生成部の概略構成を示すブロッ
ク図である。
FIG. 2 is a block diagram showing a schematic configuration of a test driver generation unit.

【図3】テストドライバを生成する手順を示すフローチ
ャートである。
FIG. 3 is a flowchart showing a procedure for generating a test driver.

【図4】テスト実行時の処理の流れを示すフローチャー
トである。
FIG. 4 is a flowchart showing a flow of processing when a test is executed.

【図5】テスト実行時の処理の流れを示すフローチャー
トである。
FIG. 5 is a flowchart showing the flow of processing when a test is executed.

【図6】サンプルプログラムの具体例を示す図である。FIG. 6 is a diagram showing a specific example of a sample program.

【図7】テストデータの具体例を示す図である。FIG. 7 is a diagram showing a specific example of test data.

【図8】テスト実行結果を示す図である。FIG. 8 is a diagram showing a test execution result.

【符号の説明】[Explanation of symbols]

1 モジュールインタフェース情報入力部 2 テストドライバ生成部 2a ドライバプログラム生成部 2b テスト実行プログラム生成部 2c プログラム合成部 3 テストドライバ 10 テスト実行プログラム 11 読み込みプログラム生成手段 12 実行プログラム生成手段 13 制限時間設定プログラム生成手段 14 実行結果出力プログラム生成手段 20 ドライバプログラム 21 第1のドライバプログラム生成手段 22 第2のドライバプログラム生成手段 23 第3のドライバプログラム生成手段 1 Module Interface Information Input Unit 2 Test Driver Generation Unit 2a Driver Program Generation Unit 2b Test Execution Program Generation Unit 2c Program Synthesis Unit 3 Test Driver 10 Test Execution Program 11 Reading Program Generation Means 12 Execution Program Generation Means 13 Time Limit Setting Program Generation Means 14 Execution Result Output Program Generation Means 20 Driver Program 21 First Driver Program Generation Means 22 Second Driver Program Generation Means 23 Third Driver Program Generation Means

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 テスト対象のモジュールのインタフェー
ス情報を入力するためのインタフェース情報入力部と、 上記テスト対象のモジュールを実際に実行させるテスト
を行うようにするテスト実行プログラムを自動的に生成
するテスト実行プログラム生成部と、 上記テスト実行プログラム生成部により生成されたテス
ト実行プログラムを、独立した別のプロセスとして実行
させるようにするためのドライバプログラムを自動的に
生成するドライバプログラム生成部と、 上記テスト実行プログラム生成部により生成されたテス
ト実行プログラムと、上記ドライバプログラム生成部に
より生成されたドライバプログラムとを合成してテスト
ドライバを生成するプログラム合成部とを具備すること
を特徴とするソフトウェアテスト用ドライバ自動生成装
置。
1. An interface information input section for inputting interface information of a module to be tested, and a test execution for automatically generating a test execution program for actually executing the module to be tested. A program generation unit, a driver program generation unit that automatically generates a driver program for executing the test execution program generated by the test execution program generation unit as a separate process, and the test execution described above. A software test driver automatic system, comprising: a test execution program generated by a program generation unit; and a program synthesis unit that synthesizes a driver program generated by the driver program generation unit to generate a test driver. Living Equipment.
【請求項2】 上記テスト実行プログラム生成部は、テ
ストデータを読み込むためのプログラムと、 上記テストを開始してから一定時間が経過した後は上記
テストを異常終了させることにより、上記テスト対象の
モジュールの無限ループを判断するようにするためのプ
ログラムと、 上記テスト対象のモジュールに読み込んだテストデータ
を渡して実行するためのプログラムと、 上記テスト対象のモジュールの実行結果を出力するため
のプログラムとを生成することを特徴とする請求項1に
記載のソフトウェアテスト用ドライバ自動生成装置。
2. The test execution program generation unit includes a program for reading test data and a module to be tested by abnormally ending the test after a lapse of a certain time from the start of the test. The program to judge the infinite loop of, the program to pass the test data read to the module to be tested and execute it, and the program to output the execution result of the module to be tested. An automatic driver generation device for software testing according to claim 1, wherein the automatic driver generation device is for generating.
【請求項3】 上記ドライバプログラム生成部は、テス
ト実行プログラムを独立した別のプロセスとして実行さ
せるためのプログラムと、 上記テスト実行プログラムを独立した別のプロセスとし
て実行させた時に、そのテスト実行プログラムを実行し
たプロセスの終了状態を検査するためのプログラムと、 上記テスト実行プログラムがなんらかの異常発生により
終了していた場合に、その異常終了のテスト実行結果を
出力するためのプログラムと、 上記の処理を行うプログラムを全てのテストデータに対
して実行させるプログラムとを生成することを特徴とす
る請求項1に記載のソフトウェアテスト用ドライバ自動
生成装置。
3. The driver program generation section executes a test execution program as a separate independent process, and a test execution program when the test execution program is executed as an independent separate process. A program for checking the end status of the executed process, and a program for outputting the test execution result of the abnormal termination when the above test execution program has terminated due to some abnormality, and the above processing 2. A software test driver automatic generation device according to claim 1, wherein the program is generated to execute the program for all test data.
JP6264507A 1994-10-04 1994-10-04 Automatic driver generating device for software test Pending JPH08106404A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6264507A JPH08106404A (en) 1994-10-04 1994-10-04 Automatic driver generating device for software test

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6264507A JPH08106404A (en) 1994-10-04 1994-10-04 Automatic driver generating device for software test

Publications (1)

Publication Number Publication Date
JPH08106404A true JPH08106404A (en) 1996-04-23

Family

ID=17404205

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6264507A Pending JPH08106404A (en) 1994-10-04 1994-10-04 Automatic driver generating device for software test

Country Status (1)

Country Link
JP (1) JPH08106404A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8368915B1 (en) 2006-06-23 2013-02-05 Open Invention Network, Llc System and method for printer driver management in an enterprise network

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8368915B1 (en) 2006-06-23 2013-02-05 Open Invention Network, Llc System and method for printer driver management in an enterprise network

Similar Documents

Publication Publication Date Title
JPH01180645A (en) Automatic verification system for maintenance diagnosing mechanism
JPH08106404A (en) Automatic driver generating device for software test
US7111212B2 (en) Debugging system for semiconductor integrated circuit
JPH08328905A (en) Method and device for simulation
JPH05298204A (en) Test circut for input/output processor
JPH10289129A (en) Task scheduler for debugging
KR100340049B1 (en) Method for testing chill programs using test scenario
JP2544416B2 (en) Test data generation processing method
JPH1031584A (en) Automatic device for verification of software
JPH07319730A (en) Test debugging method
JP2679153B2 (en) Fault handling function test method
JPH0497445A (en) Diagnostic system for information processor
JPS6014351A (en) Automatic test system
JPH0214734B2 (en)
JP2549690B2 (en) Pseudo-fault test method for channel processor
JPH0689203A (en) Program collective test device
JPH07105045A (en) Debugging system for information processor function test program
JPH10232795A (en) Software component combination test method
JP2746180B2 (en) Program test support management device and program test support management method
JP2813252B2 (en) Fault diagnosis method for information processing equipment
JPH06139093A (en) System for reproducing test of hardware fault
JPH05233349A (en) Automatic test tool for program module
JPH0895817A (en) Method for testing information processor
JPS59161736A (en) Program analyzer
JPH11338727A (en) Testing method for information processor

Legal Events

Date Code Title Description
A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20010410