JP3119400B2 - Module test support equipment - Google Patents

Module test support equipment

Info

Publication number
JP3119400B2
JP3119400B2 JP05040204A JP4020493A JP3119400B2 JP 3119400 B2 JP3119400 B2 JP 3119400B2 JP 05040204 A JP05040204 A JP 05040204A JP 4020493 A JP4020493 A JP 4020493A JP 3119400 B2 JP3119400 B2 JP 3119400B2
Authority
JP
Japan
Prior art keywords
test
module
under test
stub
module under
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.)
Expired - Fee Related
Application number
JP05040204A
Other languages
Japanese (ja)
Other versions
JPH06250884A (en
Inventor
広行 菅原
龍郎 村上
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 Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone 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 Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP05040204A priority Critical patent/JP3119400B2/en
Publication of JPH06250884A publication Critical patent/JPH06250884A/en
Application granted granted Critical
Publication of JP3119400B2 publication Critical patent/JP3119400B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】本発明は、モジュール構造を持つ
大規模ソフトウェアの、複数者による分散協調開発にお
いて、その試験工程の、特にモジュール単体試験を支援
する装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an apparatus for supporting a test process, particularly a module unit test, in distributed cooperative development of large-scale software having a module structure by a plurality of persons.

【0002】[0002]

【従来の技術】近年、実用生産物に占めるソフトウェア
の割合が大幅に増加してきており、ソフトウェア開発効
率の向上が急務となっている。なかでも試験工程に要す
る労力は、全開発工程に要する稼働の約半分を占め、試
験工程の効率化が重要な課題となっている。
2. Description of the Related Art In recent years, the ratio of software to practical products has been greatly increased, and there is an urgent need to improve software development efficiency. In particular, the labor required for the test process accounts for about half of the operation required for the entire development process, and improving the efficiency of the test process is an important issue.

【0003】一つのプログラムのサブプログラム、サブ
ルーチン、またはプロシージャをモジュール、それらを
試験することをモジュール試験と呼ぶことにすると、モ
ジュール構造を持つ大規模ソフトウェアのモジュール試
験においては、入力パラメータを設定しそのモジュール
を起動する疑似プログラム(以後、ドライバと呼ぶ)
や、そのモジュールによって呼び出されるプログラムの
疑似プログラム(以後、スタブと呼ぶ)を多数作成しな
ければならない。また、そのモジュールの動作に影響す
る多数の入力パラメータや外部変数に試験の条件に応じ
て適当な値を設定しなければならない。
A subprogram, subroutine, or procedure of one program is called a module, and testing them is called a module test. In a module test of a large-scale software having a module structure, input parameters are set and the parameters are set. Pseudo program that starts the module (hereinafter called driver)
In addition, many pseudo programs (hereinafter, referred to as stubs) of programs called by the module must be created. In addition, appropriate values must be set for a number of input parameters and external variables that affect the operation of the module according to the test conditions.

【0004】分散開発環境下では、独立工程であるソー
スコード作成の段階で高品質を確保することが後工程の
効率化に大きく寄与する。プログラム部品であるソース
モジュール単位を対象としたモジュール試験は、この目
的に合致したものであるが、上記のように試験環境準備
やデータ設定に時間がかかることが大きな阻害要因とな
っている。
In a distributed development environment, ensuring high quality at the stage of source code creation, which is an independent process, greatly contributes to the efficiency of the post-process. The module test for each source module, which is a program component, meets this purpose, but it takes a long time to prepare the test environment and set data as described above, which is a major obstacle.

【0005】スタブおよびドライバの自動生成や入力パ
ラメータ等の設定に関して、種々の方法が提案されてい
るが、予めテスト・ケース(入力と予想出力)を非手続
き言語でコード化し、データ・ベースに保存し、これを
もとに自動試験を行なうものがある(D.J.Panzl 'Autom
atic Software Test Drivers,' Computer, 11(4), 197
8. )。これはトップダウンテストの場合はスタブの代
わりとしても使用できるが、被試験モジュールから呼ば
れる存在しないモジュールに対するテストケースを予め
書いておく必要がある。
Various methods have been proposed for automatic generation of stubs and drivers and setting of input parameters and the like. However, test cases (inputs and expected outputs) are coded in a non-procedural language in advance and stored in a database. Some of them perform automatic tests based on this (DJPanzl 'Autom
atic Software Test Drivers, 'Computer, 11 (4), 197
8.). Although this can be used as a substitute for a stub in the case of a top-down test, it is necessary to write a test case for a non-existent module called from a module under test in advance.

【0006】[0006]

【発明が解決しようとする課題】しかし、今日、ソフト
ウェア規模が増大し、モジュール構造化が進む一方、分
散・分担協調開発による効率化が行われてきており、上
記方法では各モジュール毎に必要なテスト・ケースを全
て予め作成する必要があり、また、スタブを自動生成し
ようとする場合には、存在しないモジュールのテスト・
ケースを作成し、トップダウン的に試験を行わなくては
いけないため、モジュール単体試験支援としては稼働が
大きすぎる上に、分散並行開発の利点を損なう場合もあ
る。
However, while the software scale has been increasing and the module structure has been advanced today, the efficiency has been improved by distributed and shared cooperative development. It is necessary to create all test cases in advance, and when trying to automatically generate stubs, test
Since cases must be created and tested from the top down, the operation is too large to support module unit testing, and the advantages of distributed parallel development may be impaired.

【0007】また、テスト・ケースの作成に着目すれ
ば、実際には被試験モジュール内で参照されない入力デ
ータの値も設定しなくてはならない。
In addition, if attention is paid to the creation of a test case, it is necessary to set input data values that are not actually referenced in the module under test.

【0008】本発明の目的は、モジュール単体試験を効
率的に行なうことができるモジュール試験支援装置を提
供することにある。
An object of the present invention is to provide a module test support device capable of efficiently performing a module unit test.

【0009】[0009]

【0010】本発明のモジュール試験支援装置は、試験
ログからテストケースを抽出し、試験データ管理ファイ
ルに登録する試験データ抽出・登録手段と、改版後に自
動生成されたドライバ、スタブおよびデバッガ制御コマ
ンド列ファイルと、改版前のドライバ、スタブおよび改
版前のテストケースが付加されたデバッガ制御コマンド
列ファイルとを比較し、再利用可能なテストケースを前
記試験データ管理ファイルから抽出し、その入力情報/
出力情報を埋め込んだバッチモードのデバッガ制御コマ
ンド列ファイルを生成する試験データ再利用手段とを有
する。
[0010] A module test support apparatus of the present invention extracts test cases from a test log and registers them in a test data management file, and a driver, stub, and debugger control command sequence automatically generated after revision. The file is compared with a debugger control command string file to which a driver, stub, and a test case before the revision are added, and a reusable test case is extracted from the test data management file.
Test data reuse means for generating a batch mode debugger control command string file in which output information is embedded.

【0011】[0011]

【作用】本発明は、具体的には、以下のことを行なう。The present invention specifically performs the following.

【0012】(A)被試験モジュールを呼び出すドライ
バ、および被試験モジュールから呼ばれるスタブを自動
生成する。また、ドライバが被試験モジュールを呼び出
す時点での実行の一時停止、スタブが被試験モジュール
から呼び出された時点での実行の一時停止と、スタブの
入力パラメータの出力、スタブが被試験モジュールに結
果を返す時点での実行の一時停止、ドライバが被試験モ
ジュールから結果を受けとった時点での実行の一時停止
と、被試験モジュールの出力パラメータ値(これらが構
造を持つ場合は被試験モジュール内で作用を受ける可能
性のあるフィールドのみ)の表示をそれぞれ行なうデバ
ッガ制御コマンド列を自動生成する。
(A) A driver for calling a module under test and a stub called from the module under test are automatically generated. It also suspends execution when the driver calls the module under test, pauses execution when the stub is called from the module under test, outputs stub input parameters, and outputs the result to the module under test. Suspend execution at the time of return, suspend execution at the time the driver receives the result from the module under test, and output parameter values of the module under test (if they have a structure, Automatically generates a debugger control command sequence for displaying each of the fields that may be received.

【0013】(B)被試験モジュールがプロセス定義で
ある場合において、この被試験モジュールに対するドラ
イバおよびスタブを自動生成する。また、ドライバが被
試験モジュールを起動する時点での実行の一時停止、ス
タブが被試験モジュールから呼び出された時点での実行
の一時停止と、スタブの入力パラメータの出力、スタブ
が被試験モジュールに結果を返す時点での実行の一時停
止を行なうデバッガ制御コマンド列を自動生成する。
(B) When the module under test has a process definition, a driver and a stub for the module under test are automatically generated. It also suspends execution when the driver starts the module under test, suspends execution when the stub is called from the module under test, outputs stub input parameters, and outputs the stub to the module under test. Automatically generates a debugger control command sequence that suspends execution when returning.

【0014】(C)被試験モジュールによって起動され
るモジュールがプロセス定義である時、これを疑似する
スタブと、被試験モジュールの信号の送受信に関わるプ
ロセスの疑似プロセスを自動生成する。また、信号受信
待ちの被試験モジュールに対し該当プロセスが信号を送
信する時点での実行の一時停止、被試験モジュールによ
ってプロセスが起動された時点での実行の一時停止と、
起動されたプロセスが受けとったパラメータの出力、被
試験モジュールから他プロセスが信号を受けとった時点
での実行の一時停止とその信号の出力を行なうデバッガ
制御コマンド列を自動生成する。
(C) When a module activated by the module under test has a process definition, a stub for simulating the process definition and a pseudo process of a process related to transmission and reception of a signal of the module under test are automatically generated. In addition, the execution of the process is suspended when the process transmits a signal to the module under test waiting for signal reception, the execution is suspended when the process is started by the module under test,
It automatically generates a debugger control command sequence for outputting the parameters received by the activated process, suspending the execution when another process receives a signal from the module under test, and outputting the signal.

【0015】(D)被試験モジュールの入力パラメータ
および外部定義変数のうち、被試験モジュール内で使用
される要素名とその型定義、これらが構造を持つ場合は
必要なフィールドとその型定義だけを表示し、また、被
試験モジュールによって呼ばれる外部定義モジュールの
出力パラメータのうち、被試験モジュール内で使用され
る要素名とその型定義、これらが構造を持つ場合は必要
なフィールドとその型定義だけを表示するデバッガ制御
コマンド列を自動生成する。
(D) Of the input parameters and externally defined variables of the module under test, only the element names used in the module under test and their type definitions, and if these have a structure, only the necessary fields and their type definitions Of the output parameters of the externally defined module to be displayed and called by the module under test, only the element names used in the module under test and their type definitions, and if they have a structure, only the necessary fields and their type definitions Automatically generate a debugger control command string to be displayed.

【0016】(E)信号受信待ち状態にある被試験モジ
ュールが、それに対し信号を送信するプロセスから受信
する信号の名前とパラメータのうち、被試験モジュール
内で使用される要素とその型定義、これらが構造を持つ
場合は必要なフィールドとその型定義だけを表示するデ
バッガ制御コマンド列を自動生成する。
(E) Among the names and parameters of the signals received by the module under test in the signal reception waiting state from the process of transmitting signals thereto, the elements used in the module under test and their type definitions, If the has a structure, it automatically generates a debugger control command sequence that displays only the necessary fields and their type definitions.

【0017】(F)上記で自動生成されたスタブ、ドラ
イバ、デバッガ制御コマンド列に加え、試験者が入力し
た情報およびデバッガ出力結果情報をシステム内に保持
する。そして、被試験モジュールが変更された場合、変
更前のデバッガ制御コマンド列と変更後のそれとを比較
し、実行の一時停止コマンド部分を対応付け、一時停止
時の試験者の入力情報を変更後のコマンド列ファイルに
自動追加する。また、変更を生じたモジュールの試験に
おいて得られたデバッガ出力結果情報と、システム内に
保持している変更前のモジュールに対する出力情報との
対応部分を自動抽出し、その対応部分を比較して一致し
ているかどうかを自動判定する。
(F) In addition to the automatically generated stub, driver, and debugger control command strings, information input by the tester and debugger output result information are stored in the system. Then, when the module under test is changed, the debugger control command sequence before the change is compared with that after the change, the execution pause command portion is associated, and the tester input information at the time of the pause is changed after the change. Automatically add to command string file. In addition, a corresponding portion between the debugger output result information obtained in the test of the module in which the change occurred and the output information of the module before the change held in the system is automatically extracted, and the corresponding portion is compared. Automatically determine whether or not

【0018】上記(A)により、ドライバやスタブが自
動生成され、人間がわざわざコーディングしたり、ソー
スコードを書き換えたりする必要がなくなり、また、被
試験モジュールの出力結果の確認が容易となる。これに
加え、上記(D)により、入力パラメータ値およびスタ
ブの出力パラメータ値の設定を容易かつ必要最小限に行
える。
According to the above (A), the driver and the stub are automatically generated, so that there is no need for a person to code or rewrite the source code, and the output result of the module under test can be easily confirmed. In addition, according to the above (D), the setting of the input parameter value and the output parameter value of the stub can be easily and minimized.

【0019】上記(B)により、被試験モジュールがプ
ロセス定義の場合にも、上記作用が可能となる。
According to the above (B), even when the module under test has a process definition, the above operation can be performed.

【0020】上記(C)により、被試験モジュールがプ
ロセスを起動したり、信号の送受信を行なう場合におい
ても、これに対するスタブが自動生成され、人間がわざ
わざコーディングしたり、ソースコードを書き換えたり
する必要がなくなる。また、これに加え、上記(E)に
より、スタブから送信される信号の設定を容易かつ必要
最小限に行える。
According to the above (C), even when the module under test activates a process or transmits / receives a signal, a stub corresponding to the stub is automatically generated, and it is necessary for a human to bother to code or rewrite the source code. Disappears. Further, in addition to the above, the setting of the signal transmitted from the stub can be easily and minimally performed by the above (E).

【0021】上記(F)により、一度行った試験の再現
が可能になり、また、変更を生じたモジュールに対する
再試験にかかる作業を最小限に抑えることができる。
According to the above (F), it is possible to reproduce the test once performed, and it is possible to minimize the work of retesting the changed module.

【0022】[0022]

【実施例】次に、本発明の実施例について図面を参照し
て説明する。
Next, embodiments of the present invention will be described with reference to the drawings.

【0023】ここでは、CHILL言語による大規模ソ
フトウェア開発に対する実施例を示す。関連のあるデー
タ定義、プロシージャ定義、大プロセス定義等の集まり
を、プログラム中のサブプログラム、サブルーチン、プ
ロシージャのモジュールと区別するためにCHILLモ
ジュールと呼ぶことにする。
Here, an embodiment for large-scale software development using the CHILL language will be described. A collection of related data definitions, procedure definitions, large process definitions, and the like will be referred to as a CHILL module to distinguish them from subprograms, subroutines, and procedure modules in a program.

【0024】図1は本発明の一実施例のモジュール試験
支援装置の構成図である。
FIG. 1 is a block diagram of a module test support apparatus according to one embodiment of the present invention.

【0025】モジュール試験支援装置1は入出力装置4
と接続され、処理装置2と記憶装置3から構成されてい
る。処理装置2は構文・意味解析部5とドライバ自動生
成部6とスタブ自動生成部7とデバッガ制御コマンド列
自動生成部8とコンパイラ/リンカ9とデバッガ10と
ログ生成部11と試験データ抽出部12と試験データ登
録部13と試験データ再利用部14で構成されている。
記憶装置3はユーザ用作業領域15と試験データ管理フ
ァイル16を含んでいる。なお、各部の機能については
後述する。
The module test support device 1 includes an input / output device 4
And a processing device 2 and a storage device 3. The processing device 2 includes a syntax / semantic analysis unit 5, an automatic driver generation unit 6, an automatic stub generation unit 7, an automatic debugger control command sequence generation unit 8, a compiler / linker 9, a debugger 10, a log generation unit 11, and a test data extraction unit 12. And a test data registration unit 13 and a test data reuse unit 14.
The storage device 3 includes a user work area 15 and a test data management file 16. The function of each unit will be described later.

【0026】図2はモジュール単体試験時の装置構成図
である。
FIG. 2 is a diagram showing the configuration of the apparatus during the module unit test.

【0027】まず、ソースプログラムである被試験モジ
ュール17を構文・意味解析部5に入力することによ
り、構文・意味解析されたソースコード情報を収めた中
間ファイル18を得る。以下に説明する、ドライバ自動
生成部6、スタブ自動生成部7、そしてデバッガ制御コ
マンド列自動生成部8は、それぞれこの中間ファイル1
8に保存された情報をもとに各ファイルを生成する。
First, by inputting the module under test 17 as a source program to the syntax / semantic analysis unit 5, an intermediate file 18 containing source code information subjected to syntax / semantic analysis is obtained. The automatic driver generation unit 6, the automatic stub generation unit 7, and the automatic debugger control command sequence generation unit 8, which will be described below,
Each file is generated based on the information stored in 8.

【0028】ドライバ自動生成部6は、中間ファイル1
8に収められた被試験モジュール情報を元に、以下の手
順でドライバ19を作成する。第1に、入出力パラメー
タの有無を調べる。被試験モジュールが入力パラメータ
あるいは出力パラメータを持つかどうか調べ、パラメー
タを伴う場合は、そのパラメータの変数名、型定義情報
を中間ファイル18から抽出し、ドライバモジュールフ
ァイルに型定義文の記述、パラメータ付被試験モジュー
ルの呼び出し文の記述をそれぞれ行なう。ここでは、入
力パラメータには、値は設定されていない。パラメータ
を伴わない場合は、被試験モジュールの呼び出し文だけ
を記述する。ただし、被試験モジュール呼び出し記述
は、被試験モジュールがプロシージャ(PROC)であ
るかプロセス(PROCESS)であるかで異なる。第
2に、被試験モジュールが他プロセスからの信号を受信
するかどうか調べる。もし、信号を受信する場合は、被
試験モジュールに対し信号を送信するスタブプログラム
の起動文をドライバモジュール19に追加する。第3
に、被試験モジュールが他プロセスに対し信号を送信す
るかどうか調べる。もし、信号を送信する場合は、被試
験モジュールからの信号を受信するスタブプログラムの
起動文をドライバモジュール19に追加する。
The driver automatic generation unit 6 stores the intermediate file 1
The driver 19 is created in the following procedure based on the information on the module under test stored in 8. First, the existence of input / output parameters is checked. It checks whether the module under test has an input parameter or an output parameter. If a parameter is involved, the parameter name and type definition information of the parameter are extracted from the intermediate file 18 and the description of the type definition statement and the parameter Each of the call statements of the module under test is described. Here, no value is set for the input parameter. If no parameter is involved, describe only the call statement of the module under test. However, the module under test call description differs depending on whether the module under test is a procedure (PROC) or a process (PROCESS). Second, it checks whether the module under test receives a signal from another process. If a signal is received, an activation statement of a stub program for transmitting a signal to the module under test is added to the driver module 19. Third
Next, it is checked whether the module under test transmits a signal to another process. If a signal is to be transmitted, an activation statement of a stub program for receiving a signal from the module under test is added to the driver module 19.

【0029】次に、スタブ自動生成部7について説明す
る。スタブには、被試験モジュールによって呼び出され
るプロシージャあるいはプロセス、被試験モジュールと
信号を送信あるいは受信するプロセスがある。 (1)被試験モジュールによって他CHILLモジュー
ルのプロシージャが呼び出される場合、このCHILL
モジュール名と同名のCHILLモジュールを作成し、
同名のプロシージャを記述する。その呼び出されるモジ
ュールが入力パラメータ、あるいは出力パラメータを伴
うかどうかを調べ、パラメータを持つ場合は、その変数
定義に関する記述を追加する。 (2)また、被試験モジュールがプロセスを起動する場
合も、同様にして行なう。ただし、プロセスの場合は、
プロシージャではなくプロセス定義を記述する。 (3)被試験モジュールが他プロセスから信号を受信す
る場合、被試験モジュールのプロセスIDをパラメータ
として受けとり、そのIDに対して信号名対応に信号を
送信するプロセス定義を記述したCHILLモジュール
を作成する。信号がパラメータを持つ場合、パラメータ
変数の定義文を追加し、パラメータ付シグナルを送信す
る記述にする。 (4)また、被試験モジュールが他プロセスに対し信号
を送信する場合は、そのシグナルを信号名対応に受信す
るプロセス定義を記述する。
Next, the automatic stub generation unit 7 will be described. The stub includes a procedure or process called by the module under test, and a process of transmitting or receiving a signal from the module under test. (1) When a procedure of another CHILL module is called by the module under test, this CHILL module
Create a CHILL module with the same name as the module name,
Write a procedure with the same name. Check whether the called module has an input parameter or an output parameter, and if so, add a description about the variable definition. (2) When the module under test starts a process, the process is performed in the same manner. However, for processes,
Write process definitions, not procedures. (3) When the module under test receives a signal from another process, a CHILL module that describes a process definition for receiving the process ID of the module under test as a parameter and transmitting a signal corresponding to the signal name to the ID is created. . If the signal has parameters, add a parameter variable definition statement to describe the transmission of the signal with parameters. (4) When the module under test transmits a signal to another process, a process definition for receiving the signal corresponding to the signal name is described.

【0030】次に、デバッガ制御コマンド列自動生成部
8について説明する。この実施例で実際に対象とした交
換プログラムの特徴として、・手続き呼び出し関係が複
雑である、・スタティックデータとして状態を保持す
る、・パラメータをリスト形式で引き渡す、といったこ
とが挙げられる。これらの特徴を考慮し、以下のような
入力−出力モデルを考える。すなわち、被試験プログラ
ムの入力パラメータ、参照スタティックデータ、手続き
呼び出しの出力パラメータ、受信シグナルを入力、被試
験プログラムの出力パラメータ、設定スタティックデー
タ、手続き呼び出しの入力パラメータ、送信シグナルを
出力として、入力情報のセットでテストケースを規定
し、出力情報のセットで結果を判定する。
Next, the debugger control command sequence automatic generation section 8 will be described. The features of the exchange program actually targeted in this embodiment include: the procedure call relationship is complicated; the state is held as static data; and the parameters are delivered in a list format. Considering these characteristics, consider the following input-output model. That is, the input parameters of the program under test, the reference static data, the output parameters of the procedure call, the received signal are input, the output parameters of the program under test, the set static data, the input parameters of the procedure call, and the transmission signal are output, and A test case is defined by a set, and a result is determined by a set of output information.

【0031】前述のドライバ自動生成部6およびスタブ
自動生成部7で生成されたドライバ19およびスタブ2
0は、入力データが未設定である。デバッガ制御コマン
ド列自動生成部8は、この入力データの設定および出力
情報の確認を対話的に促すためのデバッガ制御コマンド
列ファイル21を生成する。すなわち、入力データ設定
箇所の特定、そして、その入力のうち実行文中で実際に
使用されるフィールドの特定を行なう。以下に、具体的
に説明する。
The driver 19 and the stub 2 generated by the automatic driver generation unit 6 and the automatic stub generation unit 7 described above.
0 indicates that the input data has not been set. The debugger control command sequence automatic generation unit 8 generates a debugger control command sequence file 21 for interactively prompting the setting of the input data and the confirmation of the output information. That is, the input data setting location is specified, and the field of the input that is actually used in the executable statement is specified. The details will be described below.

【0032】入力は、被試験モジュールがドライバ19
から受けとるパラメータ、スタティックデータ、プロシ
ージャ呼び出しのリターンデータ、受信シグナルであ
る。デバッガ制御コマンド列自動生成部8は、ソースコ
ードを構文解析することにより得られた中間ファイル1
8の情報、および自動生成されたドライバ19、スタブ
20のソース情報を元に、ドライバ19が被試験モジュ
ールを呼び出す箇所、スタティックデータが最初に使用
される箇所、スタブ20が被試験モジュールに対しリタ
ーンデータを渡す箇所、スタブ20が被試験モジュール
に対しシグナルを送信する箇所をそれぞれ特定する。次
に、それらの入力がどのような構造を持っているか、ど
の入力の、どのフィールドが、実際に被試験モジュール
の実行文で使用されるかを特定する。こうしてデバッガ
制御コマンド列自動生成部8は、データ設定を必要とす
る箇所で実行を停止するコマンドを記述し、その停止時
に実行するデバッガコマンド、すなわち、変数のどのフ
ィールドの設定が必要なのか、またどういった型のデー
タを設定すれば良いのかを表示するコマンド記述、試験
者の入力データを受けとり設定するコマンド、データ設
定後自動的に実行を再開するコマンドをそれぞれ停止コ
マンドに対応付けて記述することによって、デバッガ制
御コマンド列ファイル21を生成する。
The input is that the module under test is
Parameters, static data, procedure call return data, and received signals. The debugger control command sequence automatic generation unit 8 analyzes the intermediate file 1 obtained by parsing the source code.
8, the driver 19 calls the module under test, the location where the static data is used first, and the stub 20 returns to the module under test based on the automatically generated driver 19 and source information of the stub 20. The location where data is passed and the location where the stub 20 sends a signal to the module under test are specified. Next, it specifies what kind of structure those inputs have and what fields of which inputs are actually used in the executable statement of the module under test. In this way, the debugger control command sequence automatic generation unit 8 describes the command to stop the execution at the place where the data setting is required, and executes the debugger command to be executed at the time of the stop, that is, which field of the variable needs to be set, and A command description that indicates what type of data should be set, a command that receives and sets tester input data, and a command that automatically resumes execution after setting data are described in association with stop commands. Thereby, the debugger control command sequence file 21 is generated.

【0033】一方、出力は、被試験モジュールのドライ
バ19へのリターンデータ、被試験モジュール内で設定
(変更)されたスタティックデータ、プロシージャ呼び
出しあるいはプロセス起動時の入力パラメータ、送信シ
グナルである。デバッガ制御コマンド列自動生成部8
は、入力に関する場合と同様にして、ドライバ19が被
試験モジュールからリターンデータを受け取る箇所、ス
タティックデータが設定される箇所、被試験モジュール
によってスタブ20が呼び出される(起動される)箇
所、スタブ20がシグナルを受けとる箇所をそれぞれ特
定する。次に、どの変数フィールドが、被試験モジュー
ルの実行文によって変更されたかを特定する。こうして
デバッガ制御コマンド列自動生成部8は、出力データ確
認を必要とする箇所で実行を停止するコマンド、その停
止時に確認を必要とするデータを出力し、特に被試験モ
ジュールの実行によって変更を生じた変数フィールドに
はそれが分かるマークを付けて表示するコマンドをそれ
ぞれデバッガ制御コマンド列ファイル21に記述する。
On the other hand, the output is return data to the driver 19 of the module under test, static data set (changed) in the module under test, input parameters at the time of procedure call or process startup, and transmission signals. Debugger control command sequence automatic generation unit 8
In the same manner as in the case of input, a place where the driver 19 receives return data from the module under test, a place where static data is set, a place where the stub 20 is called (activated) by the module under test, and Identify each location to receive a signal. Next, it specifies which variable field has been changed by the executable statement of the module under test. In this way, the debugger control command sequence automatic generation unit 8 outputs a command to stop execution at a place where the output data needs to be confirmed, and outputs data that needs to be confirmed at the time of the stop. Commands to be displayed with a mark for recognizing them in the variable field are described in the debugger control command sequence file 21, respectively.

【0034】次に、試験データ抽出部12と試験データ
登録部13について説明する。交換プログラムは先に挙
げた特徴により、そのテストケースが複数の入力データ
のセットと出力データのセットとなるため、予め作成す
るのは非常に手間がかかる。一方、本発明のように対話
形式で入力データ・セットを与える場合、再試験を考慮
していかにテストケースを抽出するかが一つの課題とな
るが、試験データ抽出部12、試験データ登録部13に
よってこれを解決する。
Next, the test data extracting unit 12 and the test data registering unit 13 will be described. Due to the above-mentioned characteristics, the exchange program has a set of a plurality of sets of input data and a set of output data, so that it is very time-consuming to prepare in advance. On the other hand, when an input data set is provided in an interactive manner as in the present invention, one problem is how to extract test cases in consideration of retests. However, the test data extraction unit 12 and the test data registration unit 13 To solve this.

【0035】開発者(試験者)は、被試験モジュール、
上記ドライバ19およびスタブ20からコンパイラ/リ
ンカ9によってロード・モジュール22を生成し、デバ
ッガ10にロードする。そして、デバッガ制御コマンド
列ファイル21によって規定される手順にしたがって、
入力情報を設定し、出力情報を確認する。デバッガ10
上でのこれらの過程はすべて、デバッガ10が生成する
試験ログファイル23に保存される。試験データ抽出部
12は、この試験ログファイル23を元に入力情報セッ
ト、出力情報セットを抽出し、試験データ登録部13は
テストケース・データベースである試験データ管理ファ
イル16に登録し、管理する。
The developer (tester) includes a module under test,
A load module 22 is generated from the driver 19 and the stub 20 by the compiler / linker 9 and loaded into the debugger 10. Then, according to the procedure defined by the debugger control command sequence file 21,
Set the input information and check the output information. Debugger 10
All of the above steps are stored in a test log file 23 generated by the debugger 10. The test data extraction unit 12 extracts an input information set and an output information set based on the test log file 23, and the test data registration unit 13 registers and manages the test information in a test data management file 16 which is a test case database.

【0036】図3はモジュール再試験時の装置構成図で
ある。
FIG. 3 is a block diagram of the apparatus at the time of module retest.

【0037】被試験ソースコード改版時には、デグレー
ド確認のため、再試験が必要となる。しかし、一般にデ
バッガ制御コマンド列ファイルやテストケースファイル
を、そのまま改版時の再試験に流用することは困難であ
る。試験データ再利用部14は、以下の方法により、試
験データ抽出部12および試験データ登録部13によっ
て試験データ管理ファイル16にデータベース化されて
いる改版前の試験情報を、可能な限り再試験に適用す
る。具体的には、改版後のソースプログラム17から本
装置によって自動生成されたドライバ19、スタブ2
0、デバッガ制御コマンド列ファイル21と、改版前の
対応ファイル19’,20’,21’とをそれぞれ比較
し、特に実行停止箇所の対応関係を調べ、再利用可能な
テストケースを抽出する。停止箇所のソース行位置のズ
レは、実行文を比較することにより、動的にマッチング
をとる。そして、有効なテストケースの入力情報および
出力情報を改版後ソースコード試験用のデバッガ制御コ
マンド列ファイル21に埋め込んで、再利用可能部分に
ついては自動入力データ設定、自動結果判定できるよう
にした、バッチモードの再試験デバッガ制御コマンド列
ファイル24を生成する。これにより開発者は、ソース
コード修正にともない生じたテストケースのみ、再試験
デバッガ制御コマンド列ファイル24のサポートに従っ
てマニュアル試験すれば良い。
When the source code under test is revised, a retest is required to confirm the degrade. However, in general, it is difficult to use the debugger control command sequence file and the test case file as they are for retesting at the time of revision. The test data reuse unit 14 applies the test information before the revision, which is made into a database in the test data management file 16 by the test data extraction unit 12 and the test data registration unit 13 to the retest as much as possible by the following method. I do. Specifically, the driver 19 and the stub 2 automatically generated by the apparatus from the source program 17 after the revision
0, the debugger control command sequence file 21 is compared with the corresponding files 19 ', 20', 21 'before the revision, and the correspondence between execution stop portions is particularly checked, and a reusable test case is extracted. The displacement of the source line position at the stop point is dynamically matched by comparing executable statements. Then, the input information and the output information of the valid test case are embedded in the debugger control command string file 21 for the source code test after the revision, so that the reusable part can be set with automatic input data setting and automatic result judgment. A mode retest debugger control command sequence file 24 is generated. This allows the developer to manually test only the test cases generated due to the source code modification in accordance with the support of the retest debugger control command sequence file 24.

【0038】[0038]

【発明の効果】以上説明したように本発明は、モジュー
ルに変更や修正を生じた場合、変更前のモジュールに対
して行なった試験資源を再利用することにより、モジュ
ール単体試験を効率的に行なうことができる。
As described above, according to the present invention, when a module is changed or modified, the module unit test is efficiently performed by reusing the test resources performed on the module before the change. be able to.

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

【図1】本発明の一実施例のモジュール単体試験支援装
置の構成図である。
FIG. 1 is a configuration diagram of a module unit test support apparatus according to an embodiment of the present invention.

【図2】モジュール単体試験時の装置構成図である。FIG. 2 is an apparatus configuration diagram at the time of a module unit test.

【図3】モジュール再試験時の装置構成図である。FIG. 3 is an apparatus configuration diagram at the time of module retest.

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

1 モジュール試験支援装置 2 処理装置 3 記憶装置 4 入出力装置 5 構文・意味解析部 6 ドライバ自動生成部 7 スタブ自動生成部 8 デバッガ制御コマンド列自動生成部 9 コンパイラ/リンカ 10 デバッガ 11 ログ作成部 12 試験データ抽出部 13 試験データ登録部 14 試験データ再利用部 15 ユーザ用作業領域 16 試験データ管理ファイル 17 ソースプログラム 18 中間ファイル 19、19’ ドライバ 20、20’ スタブ 21、21’ デバッガ制御コマンド列ファイル 22 ロード・モジュール 23 試験ログファイル 24 再試験デバッガ制御コマンド列ファイル REFERENCE SIGNS LIST 1 module test support device 2 processing device 3 storage device 4 input / output device 5 syntax / semantic analysis unit 6 driver automatic generation unit 7 stub automatic generation unit 8 debugger control command sequence automatic generation unit 9 compiler / linker 10 debugger 11 log generation unit 12 Test data extraction unit 13 Test data registration unit 14 Test data reuse unit 15 User work area 16 Test data management file 17 Source program 18 Intermediate file 19, 19 'Driver 20, 20' Stub 21, 21 'Debugger control command sequence file 22 Load module 23 Test log file 24 Retest debugger control command string file

フロントページの続き (58)調査した分野(Int.Cl.7,DB名) G06F 11/28 340 G06F 9/06 540 Continuation of the front page (58) Field surveyed (Int.Cl. 7 , DB name) G06F 11/28 340 G06F 9/06 540

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 試験ログからテストケースを抽出し、試
験データ管理ファイルに登録する試験データ抽出・登録
手段と、 改版後に自動生成されたドライバ、スタブおよびデバッ
ガ制御コマンド列ファイルと、改版前のドライバ、スタ
ブおよび改版前のテストケースが付加されたデバッガ制
御コマンド列ファイルとを比較し、再利用可能なテスト
ケースを前記試験データ管理ファイルから抽出し、その
入力情報/出力情報を埋め込んだバッチモードのデバッ
ガ制御コマンド列ファイルを生成する試験データ再利用
手段とを有するモジュール試験支援装置。
1. A test data extraction / registration means for extracting a test case from a test log and registering the test case in a test data management file, a driver, stub and debugger control command string file automatically generated after the revision, and a driver before the revision , A batch mode in which a stub and a test case before the revision are added to a debugger control command string file, a reusable test case is extracted from the test data management file, and input information / output information thereof is embedded. A module test support device having test data reuse means for generating a debugger control command string file.
JP05040204A 1993-03-01 1993-03-01 Module test support equipment Expired - Fee Related JP3119400B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP05040204A JP3119400B2 (en) 1993-03-01 1993-03-01 Module test support equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP05040204A JP3119400B2 (en) 1993-03-01 1993-03-01 Module test support equipment

Publications (2)

Publication Number Publication Date
JPH06250884A JPH06250884A (en) 1994-09-09
JP3119400B2 true JP3119400B2 (en) 2000-12-18

Family

ID=12574256

Family Applications (1)

Application Number Title Priority Date Filing Date
JP05040204A Expired - Fee Related JP3119400B2 (en) 1993-03-01 1993-03-01 Module test support equipment

Country Status (1)

Country Link
JP (1) JP3119400B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0666600U (en) * 1993-02-23 1994-09-20 英機 吉増 Collection and delivery vehicles for cleaning stores, etc.

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5172585B2 (en) * 2008-10-07 2013-03-27 インターナショナル・ビジネス・マシーンズ・コーポレーション System, method, and program for controlling access to object model
JP6256115B2 (en) 2014-03-10 2018-01-10 富士通株式会社 Operation search program, operation search method, and operation search device
CN105319964B (en) * 2015-09-29 2018-06-22 上海新跃仪表厂 Carrier rocket test transmitting flow generation method and system based on configuration file

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0666600U (en) * 1993-02-23 1994-09-20 英機 吉増 Collection and delivery vehicles for cleaning stores, etc.

Also Published As

Publication number Publication date
JPH06250884A (en) 1994-09-09

Similar Documents

Publication Publication Date Title
EP0632377B1 (en) Method for testing a message-driven operating system
US6490695B1 (en) Platform independent memory image analysis architecture for debugging a computer program
US7895575B2 (en) Apparatus and method for generating test driver
US5926638A (en) Program debugging system for debugging a program having graphical user interface
US7243090B2 (en) System and method for specification tracking in a Java compatibility testing environment
WO2005055051A2 (en) Determining the possibility of adverse effects arising from a code change
CN100370432C (en) Automated testing apparatus and method for embedded software
CN113377431A (en) Code processing method, device, equipment and medium
Bothell ACT-R 7.21+ reference manual
JPH03188535A (en) Assembly language programming error detecting process
JPH11505645A (en) Apparatus and method for simulating a digital system based on a processor
JP3119400B2 (en) Module test support equipment
JPH08314760A (en) Program development supporting device
US20060074625A1 (en) Program development suport device, program execution device, compile method and debug method
US20080300846A1 (en) Methods and apparatus for hardware simulation and design verification
CN115344268A (en) Multi-platform embedded development environment compiling method and device
JP3196675B2 (en) Language processing method
CN112162921B (en) Industrial automation test and control system
CN114281709A (en) Unit testing method, system, electronic equipment and storage medium
JP3504605B2 (en) Software automatic test method
JP2828590B2 (en) Microprogram verification method
Forte Tools fair: Out of the lab, onto the shelf
US20040177350A1 (en) Windowstm f-language interpreter
EP4290368A1 (en) Computer-implemented method and system for generating a command pipeline for controlling a technical device
EP0261690B1 (en) Method for using descriptor file describing control structures file used by a dump program

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees