JP2016115175A - Software test apparatus and software test program - Google Patents

Software test apparatus and software test program Download PDF

Info

Publication number
JP2016115175A
JP2016115175A JP2014253939A JP2014253939A JP2016115175A JP 2016115175 A JP2016115175 A JP 2016115175A JP 2014253939 A JP2014253939 A JP 2014253939A JP 2014253939 A JP2014253939 A JP 2014253939A JP 2016115175 A JP2016115175 A JP 2016115175A
Authority
JP
Japan
Prior art keywords
test case
software
test
result
path
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
JP2014253939A
Other languages
Japanese (ja)
Inventor
憲明 市田
Noriaki Ichida
憲明 市田
加瀬 直樹
Naoki Kase
直樹 加瀬
秀人 小笠原
Hideto Ogasawara
秀人 小笠原
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.)
Toshiba Corp
Original Assignee
Toshiba 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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP2014253939A priority Critical patent/JP2016115175A/en
Publication of JP2016115175A publication Critical patent/JP2016115175A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To extract a necessary additional test case for software to be inspected, and to automatically output determination on success or failure thereof.SOLUTION: A software test apparatus operates as follows: inputting software to be inspected (21); generating a control flow graph formed by representing all possible paths for a program to be executed in a graphic form (23); executing an existing test case 22 on the control flow graph, and recording paths used on the control flow graph (24); generating an additional test case to be added for satisfying a predetermined complete criterion when the predetermined complete criterion based on control path test is not satisfied only with the existing test case (25); generating an expected result to be obtained as a result of executing the program in a condition in the additional test case (254); and calculating a test result of the additional test case, on the basis of an execution result of the additional test case obtained by executing only the additional test case in a test case execution section, and the expected result (26).SELECTED DRAWING: Figure 1

Description

本発明の実施形態は、ソフトウェアテスト装置およびソフトウェアテストプログラムに関する。   Embodiments described herein relate generally to a software test apparatus and a software test program.

ソフトウェアテストのテスト自動化では、検査対象ソフトウェアの変更に合わせて、テストケースとテストコードを常に保守する必要がある。   In software test automation, it is necessary to constantly maintain test cases and test codes in accordance with changes in software to be inspected.

そのため、保守のコストを削減するべく、テストケースを自動設計する技術、テストコードを自動生成する技術が提案されている。   Therefore, techniques for automatically designing test cases and techniques for automatically generating test codes have been proposed in order to reduce maintenance costs.

しかしながら、テストケース設計において、期待結果を自動的に生成するための有力な手段はない、という問題があった。これは、以下の様な理由による。   However, in test case design, there is a problem that there is no effective means for automatically generating expected results. This is due to the following reasons.

検査対象ソフトウェアから期待結果を生成しても、その期待結果が正しいか分からない。また、検査対象ソフトウェア以外に、期待結果を生成するための情報を入力するとすれば、その情報は検査対象ソフトウェアのあるべき姿そのものであり、検査対象のソフトウェアを開発する意味が無い。   Even if the expected result is generated from the inspection target software, it is not known whether the expected result is correct. Further, if information for generating an expected result is input in addition to the software to be inspected, the information is exactly what the software to be inspected should be, and there is no point in developing the software to be inspected.

同じ仕様で、2つの実装をして、入力に対する出力が同じになるかで合否を判定する方法はあるが、コストがかかるだけでなく、出力が異なるとき、どちらが間違っているかわからない。   There are two implementations with the same specification, and there is a method for judging pass / fail according to whether the output for the input is the same, but it is not only costly, but when the output is different, it is not known which is wrong.

特開2012−37938号公報JP 2012-37938 A 特開2012−185539号公報JP 2012-185539 A

本発明が解決しようとする課題は、検査対象ソフトウェアについて必要な追加テストケースを抽出し、その合否判定を自動的に出力するソフトウェアテスト装置およびソフトウェアテストプログラムを提供することである。   The problem to be solved by the present invention is to provide a software test apparatus and a software test program for extracting additional test cases necessary for software to be inspected and automatically outputting the pass / fail judgment.

実施形態のソフトウェアテスト装置は、入力した検査対象ソフトウェアについて、プログラムを実行した場合に通過してパスを通す可能性のある全ての経路をグラフで表した制御フローグラフを生成する制御フローグラフ生成部と、既にプログラムの実行を確認済みの既存テストケースを取得し、この既存テストケースを前記制御フローグラフ上で実行し、前記制御フローグラフ上で通過した経路を記録するテストケース実行部と、前記既存テストケースだけでは制御パステスト法による所定の網羅基準に満たない場合に、前記所定の網羅基準を満たすように追加される追加テストケースを生成する追加テストケース生成部と、前記追加テストケースに書かれた条件でプログラムを実行した場合に、 その結果として得られるべき期待結果を生成する期待結果生成部と、前記テストケース実行部で前記追加テストケースのみを実行して得られた前記追加テストケースの実行結果および期待結果に基づいて、前記追加テストケースのテスト結果を算出する合否判定部とを、備える。   The software test apparatus according to the embodiment generates a control flow graph that generates a control flow graph in which all paths that may pass through the path when the program is executed with respect to the input inspection target software. And a test case execution unit that acquires an existing test case that has already been confirmed to execute the program, executes the existing test case on the control flow graph, and records a path that has passed on the control flow graph; and An additional test case generation unit that generates an additional test case that is added to satisfy the predetermined coverage criterion when the existing test case alone does not satisfy the predetermined coverage criterion according to the control path test method, and the additional test case When the program is executed under the written conditions, the expected result that should be obtained as a result is generated. A test result of the additional test case is calculated based on an execution result and an expected result of the additional test case obtained by executing only the additional test case by the expected result generation unit to be generated and the test case execution unit. A pass / fail determination unit.

本発明の実施形態に係るソフトウェアテスト装置の概略構成を示すブロック図である。It is a block diagram which shows schematic structure of the software test apparatus which concerns on embodiment of this invention. 検査対象ソフトウェアの一例を示す図である。It is a figure showing an example of inspection object software. 既存テストケースの一例を示す図である。It is a figure which shows an example of the existing test case. 図2に示す検査対象ソフトウェアの制御フローグラフを示した図である。It is the figure which showed the control flow graph of the test object software shown in FIG. 図4に示す制御フローグラフのデータ構造を表す図である。It is a figure showing the data structure of the control flow graph shown in FIG. 記録する通過した経路(パス)の一例を示す図である。It is a figure which shows an example of the path | route (path | pass) to record. 不足パスの一例を示す図である。It is a figure which shows an example of a lack path | pass. 図7に示す不足パスに対応する制約(ノードの式)の一例を示す図である。It is a figure which shows an example of the restrictions (node formula) corresponding to the shortage path shown in FIG. 不足パスを通過するため入力値の一例を示す図である。It is a figure which shows an example of an input value in order to pass an insufficient path | pass. 制御フローグラフ上で通過したパスおよび不足パスを参考にして、教師データとして用いるパスの抽出の一例を示した図である。It is the figure which showed an example of the extraction of the path | pass used as teacher data with reference to the path | pass and insufficient path | pass which passed on the control flow graph. 既存テストケースから抽出された教師データの一例を示す図である。It is a figure which shows an example of the teacher data extracted from the existing test case. 回帰モデルから生成した期待結果の一例を示す図である。It is a figure which shows an example of the expected result produced | generated from the regression model. 追加テストケースの実行結果と期待結果に基づいて、テストケースのテスト結果が得られることを説明する図である。It is a figure explaining that the test result of a test case is obtained based on the execution result and expectation result of an additional test case. テスト結果一覧の出力の一例を示す図である。It is a figure which shows an example of the output of a test result list. 実施形態に係るソフトウェアテスト装置における期待結果の生成処理・テスト結果の算出処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the production | generation process of the expected result in the software test apparatus which concerns on embodiment, and the calculation process of a test result. 本実施例における検査対象ソフトウェアのソースコードを示す図である。It is a figure which shows the source code of the test object software in a present Example. 図16に示す検査対象ソフトウェアの既存テストケースを示す図である。It is a figure which shows the existing test case of the test object software shown in FIG. 検査対象ソフトウェアの仕様変更に伴い変更されたソースコードを示す図である。It is a figure which shows the source code changed with the specification change of test object software. 追加テストケースの入力値および期待結果を示す図である。It is a figure which shows the input value and expectation result of an additional test case. 追加テストケースの実行結果を示す図である。It is a figure which shows the execution result of an additional test case. テスト結果に基づくソースコードの誤りの調査を説明する図である。It is a figure explaining investigation of the error of the source code based on a test result.

以下、本発明の一実施の形態について、図面を参照して説明する。尚、各図において同一箇所については同一の符号を付すとともに、重複した説明は省略する。   Hereinafter, an embodiment of the present invention will be described with reference to the drawings. In the drawings, the same portions are denoted by the same reference numerals, and redundant description is omitted.

まず、本実施形態で用いる主要な用語について説明する。   First, main terms used in the present embodiment will be described.

「ソフトウェアテスト」とは、コンピュータのプログラムを実行し、正しく動作するかどうか確認する作業をいう。一般的に、テストケースの設計、テストの実行による結果の確認、レポート(合格、不合格一覧)の作成、のような作業をする必要がある。   “Software test” refers to an operation of executing a computer program and confirming whether or not it operates correctly. In general, it is necessary to perform tasks such as designing test cases, checking results by executing tests, and creating reports (pass / fail list).

「テストケース」とは、テストを行う際に、プログラムにどのような入力を与え、 その結果としてどのような出力が得られるべきか(期待結果)を記述したものをいう。   A “test case” is a description of what input is given to a program and what output should be obtained as a result (expected result).

「期待結果」とは、テストケースに書かれた条件でプログラムを実行したとき、 その結果として得られるべき結果をいう。   The “expected result” is the result that should be obtained when the program is executed under the conditions written in the test case.

「テスト自動化」とは、ソフトウェアテストの作業の一部を自動化することをいう。   “Test automation” refers to automating a part of software test work.

「テストコード」とは、テストケースを実行可能なプログラムとして記述したものをいう。テストの実行と結果の確認をするために実装される。   “Test code” means a test case described as an executable program. Implemented to run tests and check results.

「制御パステスト法」とは、ソフトウェアのテスト手法の一つで、プログラム中のコードが全て実行されるようにテストデータを与えるテストをいう。ソフトウェアの論理構造を分析するホワイトボックステストの一種で、プログラムの論理構造が意図した通りに記述されているか確かめるため、なるべく多くのコードが実行されるようなテストデータの組み合わせを考えてテストを行う。   The “control path test method” is one of software test methods, and refers to a test that provides test data so that all codes in a program are executed. A type of white-box test that analyzes the logical structure of software. In order to check whether the logical structure of a program is written as intended, the test is performed considering combinations of test data that can execute as many codes as possible. .

「回帰モデル」とは、ある二つの変数の関係を表す式のうち、統計的手法によって推計された式をいう。回帰式ともいう。   “Regression model” refers to an expression estimated by a statistical method among expressions expressing the relationship between two variables. Also called regression equation.

本実施形態においては、制御パステスト法で所定の基準に満たない場合に追加のテストケースを見つけ出し、追加テストケースの期待結果を確率密度関数として生成し、既存テストケースの合否結果と合わせて、追加テストケースのテスト結果を算出する。   In the present embodiment, when the control path test method does not satisfy the predetermined criteria, an additional test case is found, the expected result of the additional test case is generated as a probability density function, and combined with the pass / fail result of the existing test case, Calculate test results for additional test cases.

図1は、本発明の実施形態に係るソフトウェアテスト装置の概略構成を示すブロック図である。この装置は汎用のコンピュータ(例えばパーソナルコンピュータ(PC)等)と、同コンピュータ上で動作するソフトウェアとを用いて実現される。コンピュータとしては、CAD(Computer Aided Design)やCAE(Computer Aided Engineering)に好適なエンジニアリングワークステーション(EWS)等も含む。本実施形態はこのようなコンピュータに、検査対象ソフトウェアと既にプログラムの実行を確認済みの既存テストケースを入力し、検査対象ソフトウェアについて、プログラムを実行した場合に通過してパスを通す可能性のある全ての経路をグラフで表した制御フローグラフを生成する機能と、既存テストケースを制御フローグラフ上で実行し、制御フローグラフ上で通過した経路を記録する機能と、既存テストケースだけでは制御パステスト法による所定の網羅基準に満たない場合に、所定の網羅基準を満たすように追加される追加テストケースを生成する機能と、追加テストケースに書かれた条件でプログラムを実行した場合に、 その結果として得られるべき期待結果を生成する機能と、追加テストケースのみを実行して得られた追加テストケースの実行結果および期待結果に基づいて、追加テストケースのテスト結果を算出する機能とを、実現させるためのソフトウェアテストプログラムとして実施することもできる。   FIG. 1 is a block diagram showing a schematic configuration of a software test apparatus according to an embodiment of the present invention. This apparatus is realized using a general-purpose computer (for example, a personal computer (PC) or the like) and software operating on the computer. The computer includes an engineering workstation (EWS) suitable for CAD (Computer Aided Design) and CAE (Computer Aided Engineering). In this embodiment, there is a possibility that a test target software and an existing test case whose execution of the program has already been confirmed are input to such a computer, and the test target software passes through the path when the program is executed. A function that generates a control flow graph that represents all paths in a graph, a function that executes an existing test case on the control flow graph, records a path that passes through the control flow graph, and a control path that uses only the existing test case A function that generates additional test cases that are added to satisfy the specified coverage criteria when the specified coverage criteria by the test method are not met, and when the program is executed under the conditions written in the additional test cases, The ability to generate expected results to be obtained as a result, and additional tests obtained by executing only additional test cases The function of calculating the test result of the additional test case based on the execution result and the expected result of the strike case can also be implemented as a software test program for realizing.

図1に示すように、本実施形態に係るソフトウェアテスト装置100は、主として、検査対象ソフトウェア入力部21、既存テストケース保持部22、制御フローグラフ生成部23、テストケース実行部24、追加テストケース生成部25、合否判定部26、テスト結果一覧出力部27から構成されている。   As shown in FIG. 1, the software test apparatus 100 according to the present embodiment mainly includes a test target software input unit 21, an existing test case holding unit 22, a control flow graph generation unit 23, a test case execution unit 24, and an additional test case. The generation unit 25, the pass / fail determination unit 26, and the test result list output unit 27 are configured.

検査対象ソフトウェア入力部21は、ソフトウェアテスト装置100で検査する検査対象ソフトウェアを入力する。入力した検査対象ソフトウェアは、制御フローグラフ生成部23に送られる。検査対象ソフトウェアの入力形式は、ソースコード、あるいはバイナリ、あるいはバイトコードが好適である。図2は、検査対象ソフトウェアの一例を示す図である。図2に示す検査対象ソフトウェアは、3個の関数から成り、3番目の関数は1番目および2番目の関数を参照することを表している。   The inspection target software input unit 21 inputs inspection target software to be inspected by the software test apparatus 100. The input inspection target software is sent to the control flow graph generation unit 23. The input format of the inspection target software is preferably source code, binary, or byte code. FIG. 2 is a diagram illustrating an example of inspection target software. The inspection target software shown in FIG. 2 includes three functions, and the third function indicates that the first and second functions are referred to.

既存テストケース保持部22は、既存テストケースを保持する。ここで、既存テストケースは、プログラムの実行を確認してあり、得られるべき期待結果に問題がないものである。既存テストケースは、“入力”および“期待結果”の組として別に記録されている。入力は、“動作させる機能”および“入力値”から成り、期待結果は、“期待値”として表される。既存テストケースは、例えば、外部から既存テストケース保持部22に入力させる、あるいは、予め、既存テストケース保持部22に保持しておく。尚、検査対象ソフトウェアが既存テストケースに合格するかは不明であり、不合格となるテストケースも存在する可能性がある。その場合、当該既存テストケースは学習データ(後述する)に用いない。   The existing test case holding unit 22 holds an existing test case. Here, the existing test case has confirmed the execution of the program, and there is no problem in the expected result to be obtained. Existing test cases are recorded separately as a set of “input” and “expected result”. The input consists of “function to be operated” and “input value”, and the expected result is expressed as “expected value”. For example, the existing test case is input to the existing test case holding unit 22 from the outside, or is held in the existing test case holding unit 22 in advance. Note that it is unknown whether the inspection target software passes the existing test case, and there may be a test case that fails. In this case, the existing test case is not used for learning data (described later).

図3は、既存テストケースの一例を示す図である。図3に示す例では、5つのテストケースについて、それぞれの動作させる機能(clip_0to100やclip_0to200)、入力値(−10、83、−5、130、250)と期待結果(0、83、0、130、200)が示されている。動作させる機能は、1つのプログラムに複数存在することができ、不足パス(後述する)の出発点として使用される。既存テストケースのデータは、テストケース実行部24に送られる。   FIG. 3 is a diagram illustrating an example of an existing test case. In the example shown in FIG. 3, functions (clip_0to100 and clip_0to200), input values (−10, 83, −5, 130, and 250) and expected results (0, 83, 0, and 130) are operated for five test cases. , 200). A plurality of functions to be operated can exist in one program and are used as a starting point of a shortage path (described later). The data of the existing test case is sent to the test case execution unit 24.

制御フローグラフ生成部23は、検査対象ソフトウェア入力部21から受け取った検査対象ソフトウェアの制御フローグラフを生成する。制御フローグラフは、プログラムを実行したときに通過する、すなわち、パスを通す可能性のある全経路をグラフで表したものである。制御フローグラフの詳細は後述する。ここで、経路(パス)は、コマンドを実行するプログラムのある場所の意で、“パスを通す”とは、コマンドを実行するために、パスの設定をすることをいう。   The control flow graph generation unit 23 generates a control flow graph of the inspection target software received from the inspection target software input unit 21. The control flow graph is a graph that represents all paths that may be passed when a program is executed, that is, a path that may be passed. Details of the control flow graph will be described later. Here, a path means a place where a program for executing a command is located, and “passing a path” means setting a path to execute a command.

<制御フローグラフ>
制御フローグラフは、プログラムを実行したときに通過する、すなわち、パスを通す可能性のある全経路をグラフで表したものである。図4は、図2に示す検査対象ソフトウェアの制御フローグラフを示した図である。図4に示す例では、始点“1”から終点“5”に至るパスを通す可能性のある全経路と、始点“6”から終点“10”に至るパスを通す可能性のある全経路が示されている。動作させる機能は、制御フローグラフのノードのうち、どこからも矢印が繋がっていないノードである。
<Control flow graph>
The control flow graph is a graph that represents all paths that may be passed when a program is executed, that is, a path that may be passed. FIG. 4 is a diagram showing a control flow graph of the inspection target software shown in FIG. In the example shown in FIG. 4, there are all paths that may pass the path from the start point “1” to the end point “5” and all paths that may pass the path from the start point “6” to the end point “10”. It is shown. The function to be operated is a node in which no arrow is connected from any node in the control flow graph.

また、図5は、図4に示す制御フローグラフのデータ構造を表す図である。データ構造は、“ノード情報”と、“エッジ情報”から成っている。ノード情報は、各ノードについてのノードIDと、各ノードの内容(ノードの式)から成っている。また、エッジ情報は、始点ノードIDと終点ノードIDの組合せから成っている。図5に示す例では、ノード情報として、ノードID“1”からノードID“15”について、それぞれノードの内容(ノードの式)が示されている。さらに、エッジ情報として、各ノードIDを始点ノードIDとしたときの終点ノードIDの関係が示されている。例えば、ノードID“3”については、終点ノードIDとしてノードID“4”あるいはノードID“5”が候補であることがわかる。同様に、ノードID“15”については、終点ノードIDとしてノードID“3”あるいはノードID“8”が候補であることがわかる。   FIG. 5 is a diagram showing the data structure of the control flow graph shown in FIG. The data structure consists of “node information” and “edge information”. The node information includes a node ID for each node and the contents of each node (node expression). The edge information consists of a combination of a start point node ID and an end point node ID. In the example shown in FIG. 5, the node contents (node expressions) are shown for the node IDs “1” to “15” as the node information. Further, as edge information, the relationship of the end node ID when each node ID is set as the start node ID is shown. For example, regarding the node ID “3”, it is understood that the node ID “4” or the node ID “5” is a candidate as the end node ID. Similarly, regarding the node ID “15”, it is understood that the node ID “3” or the node ID “8” is a candidate as the end node ID.

テストケース実行部24は、既存テストケース保持部22から既存テストケースを取得し、制御フローグラフ上で実行し、制御フローグラフ上で通過した経路(パス)を記録する。図6は、記録する通過した経路(パス)の一例を示す図である。図6に示す例では、図4に示す制御フローグラフと対比すると、ノードID“3”を始点としてノードID“4”を終点とする経路(パス)が、通過した経路となっていないことがわかる。   The test case execution unit 24 acquires an existing test case from the existing test case holding unit 22, executes the test case on the control flow graph, and records a path (path) passed on the control flow graph. FIG. 6 is a diagram illustrating an example of a route that has been recorded. In the example illustrated in FIG. 6, when compared with the control flow graph illustrated in FIG. 4, a route (path) having the node ID “3” as the start point and the node ID “4” as the end point is not a route that has passed. Recognize.

追加テストケース生成部25は、追加テストケースを生成するものである。追加テストケースは、制御パステスト法で所定の“網羅基準”に満たない場合に、所定の網羅基準を満たすように追加されるテストケースである。ここで、所定の網羅基準としては、例えば、全ての条件において、それぞれ1度でもTrueあるいはFalseとなるテストケースを網羅する“条件網羅”や、全ての分岐が1度でも実行されるテストケースを網羅する“分岐網羅”が好適である。追加テストケースは、具体的には不足パス(後述する)を通るような“入力値”、“動作させる機能”および“期待結果”を記述することで特定される。不足パス1つにつき、1つの追加テストケースが生成される。尚、所定の網羅基準は、外部から追加テストケース生成部25に入力させる、あるいは、予め追加テストケース生成部25に保持しておく。   The additional test case generation unit 25 generates an additional test case. The additional test case is a test case added so as to satisfy a predetermined coverage standard when the predetermined “coverage standard” is not satisfied in the control path test method. Here, as a predetermined coverage criterion, for example, “condition coverage” that covers test cases that are true or false for each condition, or test cases that are executed even once for all branches. Covering “branch coverage” is preferred. More specifically, the additional test case is specified by describing “input value”, “function to be operated”, and “expected result” that pass through a shortage path (described later). One additional test case is generated for each missing path. The predetermined coverage standard is input from the outside to the additional test case generation unit 25 or stored in advance in the additional test case generation unit 25.

追加テストケース生成部25は、不足パス生成部251、入力値生成部252、回帰モデル生成部253、期待結果生成部254に分けることができる。   The additional test case generation unit 25 can be divided into a shortage path generation unit 251, an input value generation unit 252, a regression model generation unit 253, and an expected result generation unit 254.

不足パス生成部251は、所定の網羅基準と、既存テストケースの実行により通過したパスを比較し、不足パスを生成する。ここで、不足パスは、網羅基準により通る必要があるノード、エッジまたはそれらの組み合わせのうち、全ての既存テストケースを実行しても通らなかったノード、エッジまたはそれらの組み合わせを通るように探索された経路(パス)である。図7は、不足パスの一例を示す図である。図6に示した通過した経路(パス)の記録から、ノードID“3”を始点としてノードID“4”を終点とする経路(パス)が、通過した経路となっていないことがわかっている。図7に示す例では、ノードID“1”を始点としてノードID“5”を終点とする経路(パス)であって、ノードID“3”からノードID“4”を経由する経路(パス)が、不足パスであることが判明する。   The insufficient path generation unit 251 compares a predetermined coverage criterion with a path that has passed through execution of an existing test case, and generates an insufficient path. Here, the missing path is searched so as to pass through nodes, edges, or combinations of nodes, edges, or combinations that need to be passed according to the coverage criteria, that did not pass even if all existing test cases were executed. Route. FIG. 7 is a diagram illustrating an example of a shortage path. From the recorded route (path) shown in FIG. 6, it is known that the route (path) having the node ID “3” as the start point and the node ID “4” as the end point is not a route that has passed. . In the example illustrated in FIG. 7, a path (path) having a node ID “1” as a start point and a node ID “5” as an end point, and passing from the node ID “3” to the node ID “4”. However, it turns out that it is a shortage path.

入力値生成部252は、不足パス毎に、不足パスを通過する“ノードの式”を充足可能性問題の制約として与えて解き、不足パスを通過するため“入力値”を生成する。充足可能性問題の解は、制約を満たす具体的な1組の値が得られる。ノードの式は、制御フローグラフ生成時に作成されるもので、具体的には、図5に示すノード情報におけるノードの内容である。   For each insufficient path, the input value generation unit 252 solves the “node expression” that passes through the shortage path as a constraint on the satisfiability problem, and generates an “input value” to pass through the shortage path. As a solution to the satisfiability problem, a specific set of values that satisfy the constraints is obtained. The node formula is created when the control flow graph is generated. Specifically, the node formula is the contents of the node in the node information shown in FIG.

図8は、図7に示す不足パスに対応する制約(ノードの式)の一例を示す図である。図8に示す例では、7つのノードの式が列挙されている。図9は、不足パスを通過するため入力値の一例を示す図である。図9に示す例では、7つのノードの式を充足可能性問題として解いた解として、入力値=101となっている。上記した制約を満たす具体的な値は、尚、ノードの式の入力値が2つ以上の場合、制約を満たす具体的な値も2つ以上となることがあるが、図9に示す例では、clip_0to100 の入力値が 1 つであるため、解としての入力値は1つとなっている。上記した入力値=101は、1次元のベクトルとして扱われる。   FIG. 8 is a diagram illustrating an example of a constraint (node expression) corresponding to the shortage path illustrated in FIG. In the example shown in FIG. 8, expressions of seven nodes are listed. FIG. 9 is a diagram illustrating an example of input values for passing through a shortage path. In the example shown in FIG. 9, the input value = 101 is obtained as a solution obtained by solving the expression of seven nodes as a satisfiability problem. The specific values that satisfy the above-described constraints may be two or more specific values that satisfy the constraints when there are two or more input values in the node expression. In the example shown in FIG. , Clip_0to100 has one input value, so there is only one input value as a solution. The above input value = 101 is treated as a one-dimensional vector.

回帰モデル生成部253は、不足パス毎に、制御フローグラフ上で通過した経路(パス)の開始点と不足パスの開始点が同じになるテストケース群を既存テストケースから抽出したものを教師データとし、係る教師データを用いることで回帰モデルを生成する。図10は、制御フローグラフ上で通過したパスおよび不足パスを参考にして、教師データとして用いるパスの抽出の一例を示した図である。図11は、既存テストケースから抽出された教師データの一例を示す図である。図11に示す例では、2個の既存テストケースが教師データとして抽出されている。   The regression model generation unit 253 extracts, for each insufficient path, a test case group in which the start point of the path (path) passed on the control flow graph and the start point of the insufficient path are extracted from the existing test cases. A regression model is generated by using such teacher data. FIG. 10 is a diagram illustrating an example of extraction of paths used as teacher data with reference to the paths and insufficient paths that have passed on the control flow graph. FIG. 11 is a diagram illustrating an example of teacher data extracted from an existing test case. In the example shown in FIG. 11, two existing test cases are extracted as teacher data.

生成される回帰モデルは、(1)写像の形(線形等)を仮定しない、(2)多次元ベクトル→多次元ベクトルへの写像が可能、(3)予測を確率密度関数で得られる、という特徴を有する。   The generated regression model (1) does not assume the shape of the mapping (linear, etc.), (2) mapping from a multidimensional vector to a multidimensional vector is possible, and (3) the prediction can be obtained with a probability density function. Has characteristics.

回帰モデルとしては、例えば、ガウス過程回帰(Gaussian Process Regression)や、関連ベクトルマシン(Relevance Vector Machine)を用いることができる。ガウス過程回帰は、与えられた入力値に対して、対応する予測値がガウス分布に従う確率変数であるとするガウス過程に基づいている。   As the regression model, for example, Gaussian process regression or a related vector machine can be used. Gaussian process regression is based on a Gaussian process that assumes that the corresponding predicted value is a random variable that follows a Gaussian distribution for a given input value.

例えば、回帰モデルの式をガウス過程回帰の式で表すと、以下のようになる。
For example, if the regression model equation is expressed by a Gaussian process regression equation, it is as follows.

上記において、
ynew は、確率密度関数、xnew は、追加テストケースの入力値である。
In the above,
y new is a probability density function, and x new is an input value of an additional test case.

入力値は1つとは限らないので、xnew はベクトルである。 X new is a vector because there is not always one input value.

X は、既存テストケースの入力値を並べた行列、y は、既存テストケースの期待値を並べたベクトルである。   X is a matrix in which input values of existing test cases are arranged, and y is a vector in which expected values of existing test cases are arranged.

尚、テストによっては、複数の箇所の値(戻り値、変数など)が成功条件になるので、期待値も複数必要になることがあるが、その場合は、それぞれの戻り値、変数ごとに、モデルを作成する。β,θ、θ1、θ2 は定数であり、これらの定数は、回帰モデルが既存テストケースにフィットするように、焼きなまし法等で求める。   Depending on the test, the value (return value, variable, etc.) at multiple locations becomes a success condition, so multiple expected values may be required, but in that case, for each return value and variable, Create a model. β, θ, θ1, and θ2 are constants, and these constants are obtained by an annealing method or the like so that the regression model fits the existing test case.

期待結果生成部254は、不足パス毎に、入力値生成部252によって生成された入力値と回帰モデル生成部253によって生成された回帰モデルから、“期待結果”を生成する。本実施形態における期待結果は、平均値と分散から算出される幅をもつ確率密度関数として生成される。図12は、回帰モデルから生成した期待結果の一例を示す図である。図12に示す例では、期待結果は、確率密度関数f(x)として生成されている。   The expected result generation unit 254 generates an “expected result” from the input value generated by the input value generation unit 252 and the regression model generated by the regression model generation unit 253 for each insufficient path. The expected result in the present embodiment is generated as a probability density function having a width calculated from the average value and the variance. FIG. 12 is a diagram illustrating an example of the expected result generated from the regression model. In the example shown in FIG. 12, the expected result is generated as a probability density function f (x).

合否判定部26は、テストケース実行部24から、追加テストケースのみを実行して得られた追加テストケースの実行結果を取得し、期待結果生成部254から期待結果の確率密度関数を取得する。合否判定部26は、実行結果と期待結果に基づいて合否を計算するが、本実施形態では、期待結果を確率密度関数で表すので、合否判定部26は、テスト結果を算出する。テスト結果は、追加テストケースが合格である確率であり、追加テストケースを実行して得た値を確率密度関数に代入することで、算出する。図13は、追加テストケースの実行結果と期待結果に基づいて、テストケースのテスト結果が得られることを説明する図である。   The pass / fail determination unit 26 acquires the execution result of the additional test case obtained by executing only the additional test case from the test case execution unit 24, and acquires the probability density function of the expected result from the expected result generation unit 254. The pass / fail determination unit 26 calculates pass / fail based on the execution result and the expected result. In this embodiment, since the expected result is represented by a probability density function, the pass / fail determination unit 26 calculates the test result. The test result is a probability that the additional test case is acceptable, and is calculated by substituting a value obtained by executing the additional test case into the probability density function. FIG. 13 is a diagram illustrating that the test result of the test case is obtained based on the execution result and the expected result of the additional test case.

テスト結果一覧出力部27は、合否判定部26から、追加テストケースのテスト結果を取得し、既存テストケースおよび追加テストケースの合否結果の一覧を出力する。図14は、テスト結果一覧の出力の一例を示す図である。図14に示すように、既存テストケースは合否、追加テストケースは確率で表したテスト結果が示されている。   The test result list output unit 27 acquires the test results of the additional test cases from the pass / fail determination unit 26 and outputs a list of the pass / fail results of the existing test cases and the additional test cases. FIG. 14 is a diagram illustrating an example of the output of the test result list. As shown in FIG. 14, the test results are shown as pass / fail for the existing test case and the probability for the additional test case.

次に、以上のように構成されたソフトウェアテスト装置100における期待結果の生成処理・テスト結果の算出処理の流れについて説明する。図15は、実施形態に係るソフトウェアテスト装置100における期待結果の生成処理・テスト結果の算出処理の流れを示すフローチャートである。   Next, the flow of expected result generation processing / test result calculation processing in the software test apparatus 100 configured as described above will be described. FIG. 15 is a flowchart illustrating a flow of expected result generation processing / test result calculation processing in the software test apparatus 100 according to the embodiment.

まず、検査対象ソフトウェア入力部21は、検査対象ソフトウェアを入力する(ステップS1501)。   First, the inspection target software input unit 21 inputs inspection target software (step S1501).

次に、制御フローグラフ生成部23は、入力した検査対象ソフトウェアについて、プログラムを実行した場合に通過してパスを通す可能性のある全ての経路をグラフで表した制御フローグラフを生成する(ステップS1502)。   Next, the control flow graph generation unit 23 generates a control flow graph in which all the paths that may be passed through the path when the program is executed are expressed as a graph for the input inspection target software (step) S1502).

次に、テストケース実行部24は、既存テストケース保持部22に保持され、既にプログラムの実行を確認済みの既存テストケースを制御フローグラフ上で実行し、制御フローグラフ上で通過したパスを記録する(ステップS1503)。   Next, the test case execution unit 24 executes the existing test case that is held in the existing test case holding unit 22 and has already been confirmed to execute the program on the control flow graph, and records the path that has passed on the control flow graph. (Step S1503).

続いて、不足パス生成部251は、所定の網羅基準と、既存テストケースの実行により通過したパスを比較し、不足パスを生成する(ステップS1504)。不足パスは、所定の網羅基準により通る必要があるノード、エッジまたはそれらの組み合わせのうち、全ての既存テストケースを実行しても通らなかったノード、エッジまたはそれらの組み合わせを通るように探索された経路(パス)である。   Subsequently, the shortage path generation unit 251 compares the predetermined coverage criterion with the path that has passed through the execution of the existing test case, and generates a shortage path (step S1504). Missing paths were searched to pass through nodes, edges, or combinations of nodes, edges, or combinations that need to pass through a given coverage criterion that did not pass through all existing test cases. A route.

次に、入力値生成部252は、不足パス毎に、通過するノードの式を充足可能性問題の制約として与えて解き、入力値を生成する(ステップS1505)。   Next, the input value generation unit 252 generates an input value for each insufficient path by giving an equation of a passing node as a constraint for the satisfiability problem (step S1505).

次に、回帰モデル生成部253は、不足パス毎に、既存テストケースから、実行パスの開始点が同じになるテストケース群を抽出し、教師データとして用いることで回帰モデルを生成する(ステップS1506)。   Next, the regression model generation unit 253 extracts a test case group having the same execution path start point from existing test cases for each insufficient path, and generates a regression model by using it as teacher data (step S1506). ).

続いて、期待結果生成部254は、入力値と回帰モデルから、期待結果の確率密度関数を生成する(ステップS1507)。   Subsequently, the expected result generation unit 254 generates a probability density function of the expected result from the input value and the regression model (step S1507).

次に、テストケース実行部24は、追加テストケースのみを実行し、実行結果を合否判定部に渡す(ステップS1508)。   Next, the test case execution unit 24 executes only the additional test case and passes the execution result to the pass / fail determination unit (step S1508).

続いて、合否判定部26は、実行結果と、期待結果または期待結果の確率密度関数から合否またはテスト結果を計算する(ステップS1509)。   Subsequently, the pass / fail determination unit 26 calculates a pass / fail or test result from the execution result and the expected result or the probability density function of the expected result (step S1509).

次に、テスト結果一覧出力部27は、既存テストケースおよび追加テストケースの合否結果(既存テストケースは合否、追加テストケースはテスト結果)一覧を出力(ステップS1510)し、期待結果の生成処理・テスト結果の算出処理を終了する。   Next, the test result list output unit 27 outputs a list of pass / fail results of the existing test case and the additional test case (pass / fail for the existing test case, test result for the additional test case) (step S1510). The test result calculation process ends.

[実施例]
次に、本実施形態の実施例について説明する。本実施例は、cosxをπ/12刻みで線形補間を利用して算出する検査対象ソフトウェアである。図16は、本実施例における検査対象ソフトウェアのソースコードを示す図である。図16に示すように、本実施例では0°〜360°(2π)の範囲の角度に対応している。
[Example]
Next, examples of the present embodiment will be described. The present embodiment is inspection object software that calculates cosx by using linear interpolation in increments of π / 12. FIG. 16 is a diagram illustrating the source code of the inspection target software in the present embodiment. As shown in FIG. 16, this embodiment corresponds to an angle in the range of 0 ° to 360 ° (2π).

図17は、図16に示す検査対象ソフトウェアの既存テストケースの記録状況を示す図である。図17に示すように、0、π/12、3π/4、π、7π/6、4π/3、11π/6、2πの各入力値に対する、期待結果が記録されている。   FIG. 17 is a diagram illustrating a recording state of an existing test case of the inspection target software illustrated in FIG. As shown in FIG. 17, expected results are recorded for input values of 0, π / 12, 3π / 4, π, 7π / 6, 4π / 3, 11π / 6, and 2π.

図18は、検査対象ソフトウェアの仕様変更に伴い変更されたソースコードを示す図である。本実施例では、0°〜360°(2π)以外の範囲の角度にも対応するように仕様変更に伴う追加のソースコードが加えられている。ソフトウェアテスト装置100において、図18に示すソースコードを入力し、既存テストケースを実行する。そして、1度も通らなかった(追加された2つの while 文の条件が真になる)パスを追加テストケースとして追加する。追加テストケースの期待結果は、既存のテストケースを教師データとして与えた回帰モデルに、そのテストケースの入力値を与えることで計算する。   FIG. 18 is a diagram illustrating the source code that has been changed due to the specification change of the inspection target software. In the present embodiment, additional source code accompanying the specification change is added so as to correspond to an angle in a range other than 0 ° to 360 ° (2π). In the software test apparatus 100, the source code shown in FIG. 18 is input and an existing test case is executed. Then, a path that has never passed (the condition of the two added while statements becomes true) is added as an additional test case. The expected result of the additional test case is calculated by giving the input value of the test case to the regression model given the existing test case as teacher data.

図19は、追加テストケースの入力値および期待結果を示す図である。図19に示す例では、期待結果f(x)は、入力値(x)に対する正規分布として得られている。   FIG. 19 is a diagram illustrating input values and expected results of additional test cases. In the example shown in FIG. 19, the expected result f (x) is obtained as a normal distribution with respect to the input value (x).

追加テストケースのテスト結果は、追加テストケースの入力値(x)を検査対象ソフトウェアに与えて実行し、期待結果 を次式の実行結果 x に代入することで計算する。ここでは、回帰モデルにガウス過程回帰を用いる。
The test result of the additional test case is calculated by giving the input value (x) of the additional test case to the software to be tested and executing it, and substituting the expected result into the execution result x of the following equation. Here, Gaussian process regression is used as the regression model.

ここで、μ=期待結果の平均値、σ=分散である。   Here, μ = average value of expected results, and σ = variance.

図20は、追加テストケースの実行結果を示す図である。図20に示すように、入力値x=−0.1では、cosxの実行結果0.98696・・・が得られ、その場合のテスト結果として72.20%が得られている。一方、入力値x=−0.1では、cosxの実行結果−0.98479・・・が得られ、その場合のテスト結果として0.49%が得られている。   FIG. 20 is a diagram illustrating an execution result of the additional test case. As shown in FIG. 20, when the input value x = −0.1, the cosx execution result 0.98696... Is obtained, and the test result in that case is 72.20%. On the other hand, when the input value x = −0.1, the cosx execution result −0.98479... Is obtained, and the test result in that case is 0.49%.

図21は、テスト結果に基づくソースコードの誤りの調査を説明する図である。本実施例では、2つめの while 文の中を通る追加テストケースは、テスト結果の値が低くなっている。そこで、ソフトウェアの開発者あるいは試験担当者は、テスト結果の値が低い追加テストケースから確認することで、不具合修正活動をより効率的に行うことが出来る。図21に示すように、間違っているソースコードを効率よく抽出することができる。   FIG. 21 is a diagram for explaining an examination of source code errors based on the test results. In this embodiment, the value of the test result is low in the additional test case that passes through the second while statement. Therefore, a software developer or a person in charge of testing can perform defect correction activities more efficiently by checking from an additional test case having a low test result value. As shown in FIG. 21, an incorrect source code can be extracted efficiently.

以上説明したように、本実施形態によれば、間違っているソースコードを効率よく抽出することができるので、ソフトウェアの不具合修正活動をより効率的に行うことが出来る。   As described above, according to the present embodiment, wrong source code can be extracted efficiently, so that software defect correction activities can be performed more efficiently.

本発明のいくつかの実施形態を説明したが、これらの実施形態は、例として提示したものであり、発明の範囲を限定することは意図していない。これら新規な実施形態は、その他の様々な形態で実施されることが可能であり、発明の要旨を逸脱しない範囲で、種々の省略、置き換え、変更を行うことができる。これら実施形態やその変形は、発明の範囲や要旨に含まれるとともに、特許請求の範囲に記載された発明とその均等の範囲に含まれる。   Although several embodiments of the present invention have been described, these embodiments are presented by way of example and are not intended to limit the scope of the invention. These novel embodiments can be implemented in various other forms, and various omissions, replacements, and changes can be made without departing from the scope of the invention. These embodiments and modifications thereof are included in the scope and gist of the invention, and are included in the invention described in the claims and the equivalents thereof.

100・・・ソフトウェアテスト装置
21・・・検査対象ソフトウェア入力部
22・・・既存テストケース保持部
23・・・制御フローグラフ生成部
24・・・テストケース実行部
25・・・追加テストケース生成部
251・・・不足パス生成部
252・・・入力値生成部
253・・・回帰モデル生成部
254・・・期待結果生成部
26・・・合否判定部
27・・・テスト結果一覧出力部
DESCRIPTION OF SYMBOLS 100 ... Software test apparatus 21 ... Test object software input part 22 ... Existing test case holding part 23 ... Control flow graph generation part 24 ... Test case execution part 25 ... Additional test case generation Unit 251 ... shortage path generation unit 252 ... input value generation unit 253 ... regression model generation unit 254 ... expected result generation unit 26 ... pass / fail judgment unit 27 ... test result list output unit

Claims (13)

入力した検査対象ソフトウェアについて、プログラムを実行した場合に通過してパスを通す可能性のある全ての経路をグラフで表した制御フローグラフを生成する制御フローグラフ生成部と、
既にプログラムの実行を確認済みの既存テストケースを取得し、この既存テストケースを前記制御フローグラフ上で実行し、前記制御フローグラフ上で通過した経路を記録するテストケース実行部と、
前記既存テストケースだけでは制御パステスト法による所定の網羅基準に満たない場合に、前記所定の網羅基準を満たすように追加される追加テストケースを生成する追加テストケース生成部と、
前記追加テストケースに書かれた条件でプログラムを実行した場合に、 その結果として得られるべき期待結果を生成する期待結果生成部と、
前記テストケース実行部で前記追加テストケースのみを実行して得られた前記追加テストケースの実行結果および前記期待結果に基づいて、前記追加テストケースのテスト結果を算出する合否判定部とを、備えるソフトウェアテスト装置。
A control flow graph generation unit that generates a control flow graph that represents all paths that may pass through the path when the program is executed with respect to the input inspection target software; and
A test case execution unit that acquires an existing test case that has already been confirmed to execute the program, executes the existing test case on the control flow graph, and records a route that has passed on the control flow graph;
An additional test case generation unit that generates an additional test case that is added to satisfy the predetermined coverage criterion when the existing test case alone does not satisfy the predetermined coverage criterion by the control path test method;
An expected result generation unit that generates an expected result to be obtained as a result when the program is executed under the conditions written in the additional test case;
A pass / fail determination unit that calculates a test result of the additional test case based on the execution result of the additional test case and the expected result obtained by executing only the additional test case by the test case execution unit. Software test device.
前記検査対象ソフトウェアを入力する検査対象ソフトウェア入力部と、
前記既存テストケースを保持する既存テストケース保持部と、
を備える請求項1に記載のソフトウェアテスト装置。
An inspection target software input unit for inputting the inspection target software;
An existing test case holding unit for holding the existing test case;
The software test device according to claim 1.
前記合否判定部から、前記追加テストケースのテスト結果を取得し、前記既存テストケースおよび前記追加テストケースの合否結果の一覧を出力するテスト結果一覧出力部を
備える請求項1又は請求項2に記載のソフトウェアテスト装置。
The test result list output part which acquires the test result of the said additional test case from the said pass / fail determination part, and outputs the list of the pass / fail result of the said existing test case and the said additional test case is provided. Software testing equipment.
前記合否結果は、前記既存テストケースについては合否、前記追加テストケースについてはテスト結果である請求項3に記載のソフトウェアテスト装置。   The software test apparatus according to claim 3, wherein the pass / fail result is a pass / fail result for the existing test case and a test result for the additional test case. 前記検査対象ソフトウェアの入力形式は、ソースコード、あるいはバイナリ、あるいはバイトコードのいずれかである請求項1乃至請求項4のいずれか1項に記載のソフトウェアテスト装置。   5. The software test apparatus according to claim 1, wherein an input format of the inspection target software is any one of a source code, a binary, and a byte code. 前記所定の網羅基準は、条件網羅あるいは分岐網羅である請求項1乃至請求項5のいずれか1項に記載のソフトウェアテスト装置。   The software test apparatus according to claim 1, wherein the predetermined coverage criterion is condition coverage or branch coverage. 前記期待結果は、平均値と分散から算出される幅をもつ確率密度関数として生成される請求項1乃至請求項6のいずれか1項に記載のソフトウェアテスト装置。   The software test apparatus according to claim 1, wherein the expected result is generated as a probability density function having a width calculated from an average value and a variance. 前記追加テストケース生成部は、
前記所定の網羅基準と、前記既存テストケースの実行により通過したパスを比較し、不足パスを生成する不足パス生成部と、
前記不足パス毎に、前記不足パスを通過するノードの式を充足可能性問題の制約として与えて解き、前記不足パスを通過するための入力値を生成する入力値生成部と、
前記不足パス毎に、前記制御フローグラフ上で通過した経路の開始点と前記不足パスの開始点が同じになるテストケース群を前記既存テストケースから抽出したものを教師データとし、この教師データを用いる回帰モデルを生成する回帰モデル生成部と、
前記不足パス毎に、前記入力値生成部によって生成された入力値と前記回帰モデル生成部によって生成された前記回帰モデルから、前記期待結果を生成する前記期待結果生成部とで構成される請求項1乃至請求項5のいずれか1項に記載のソフトウェアテスト装置。
The additional test case generation unit includes:
Compare the predetermined coverage criteria and the path passed by the execution of the existing test case, and generate a shortage path, a shortage path generation unit,
An input value generation unit that generates an input value for passing through the shortage path by solving for each short path by giving an equation of a node that passes through the shortage path as a constraint of the satisfiability problem;
For each of the insufficient paths, a test case group in which the start point of the route passed on the control flow graph and the start point of the insufficient path are the same is extracted from the existing test case as teacher data, and the teacher data is A regression model generation unit for generating a regression model to be used;
The expected result generation unit configured to generate the expected result from the input value generated by the input value generation unit and the regression model generated by the regression model generation unit for each of the insufficient paths. The software test apparatus according to any one of claims 1 to 5.
前記追加テストケースは、前記不足パスを通るような入力値、動作させる機能および前記期待結果で特定される請求項8に記載のソフトウェアテスト装置。   The software test apparatus according to claim 8, wherein the additional test case is specified by an input value passing through the shortage path, a function to be operated, and the expected result. 前記動作させる機能は、前記不足パスの出発点として使用される請求項9に記載のソフトウェアテスト装置。   The software test apparatus according to claim 9, wherein the function to be operated is used as a starting point of the insufficient path. 前記不足パスは、前記所定の網羅基準により通る必要があるノード、エッジまたはそれらの組み合わせのうち、全ての前記既存テストケースを実行しても通らなかったノード、エッジまたはそれらの組み合わせを通るように探索された経路である請求項8乃至請求項10のいずれか1項に記載のソフトウェアテスト装置。   The missing path passes through a node, an edge, or a combination of nodes, an edge, or a combination thereof that needs to pass through the predetermined coverage criteria, but failed to pass even if all the existing test cases are executed. The software test apparatus according to claim 8, wherein the software test apparatus is a searched route. 前記不足パス1つにつき、1つの前記追加テストケースが生成される請求項8乃至請求項11のいずれか1項に記載のソフトウェアテスト装置。   The software test apparatus according to claim 8, wherein one additional test case is generated for each of the insufficient paths. 検査対象ソフトウェアと既にプログラムの実行を確認済みの既存テストケースを入力するソフトウェアテスト装置に、
前記検査対象ソフトウェアについて、プログラムを実行した場合に通過してパスを通す可能性のある全ての経路をグラフで表した制御フローグラフを生成する機能と、
前記既存テストケースを前記制御フローグラフ上で実行し、前記制御フローグラフ上で通過した経路を記録する機能と、
前記既存テストケースだけでは制御パステスト法による所定の網羅基準に満たない場合に、前記所定の網羅基準を満たすように追加される追加テストケースを生成する機能と、
前記追加テストケースに書かれた条件でプログラムを実行した場合に、 その結果として得られるべき期待結果を生成する機能と、
前記追加テストケースのみを実行して得られた前記追加テストケースの実行結果および期待結果に基づいて、前記追加テストケースのテスト結果を算出する機能とを、
実現させるためのソフトウェアテストプログラム。
To software test equipment that inputs software to be inspected and existing test cases that have already been confirmed to execute the program,
A function for generating a control flow graph that represents all paths that may pass through the path when the program is executed for the inspection target software; and
A function of executing the existing test case on the control flow graph and recording a route passed on the control flow graph;
A function of generating an additional test case that is added to satisfy the predetermined coverage criterion when the existing test case alone does not satisfy the predetermined coverage criterion by the control path test method;
A function for generating an expected result to be obtained as a result when the program is executed under the conditions written in the additional test case;
A function for calculating a test result of the additional test case based on an execution result and an expected result of the additional test case obtained by executing only the additional test case;
Software test program for realizing.
JP2014253939A 2014-12-16 2014-12-16 Software test apparatus and software test program Pending JP2016115175A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014253939A JP2016115175A (en) 2014-12-16 2014-12-16 Software test apparatus and software test program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014253939A JP2016115175A (en) 2014-12-16 2014-12-16 Software test apparatus and software test program

Publications (1)

Publication Number Publication Date
JP2016115175A true JP2016115175A (en) 2016-06-23

Family

ID=56140179

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014253939A Pending JP2016115175A (en) 2014-12-16 2014-12-16 Software test apparatus and software test program

Country Status (1)

Country Link
JP (1) JP2016115175A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018049492A (en) * 2016-09-23 2018-03-29 富士通株式会社 Analysis device, analysis program and analysis method
JP2019510215A (en) * 2016-06-06 2019-04-11 三菱電機株式会社 Method and sensor system for estimating the state of charge of a battery
JP2019075035A (en) * 2017-10-19 2019-05-16 株式会社日立製作所 Software test device and method
CN110399286A (en) * 2018-04-24 2019-11-01 西安邮电大学 A kind of automatic generation of test data based on independent pathway
CN110795352A (en) * 2019-10-29 2020-02-14 中国科学院微小卫星创新研究院 Establishing and using method of fine-grained test case system for component-oriented star software
KR102130016B1 (en) * 2019-09-03 2020-07-03 성균관대학교산학협력단 Method and system for compiling for automatic caching, and recoding medium therefor
KR20210023130A (en) * 2019-08-22 2021-03-04 성균관대학교산학협력단 Method and system for Data caching based on In-Memory data processing framework, and recoding medium therefor
CN114996076A (en) * 2022-07-01 2022-09-02 北京联盛德微电子有限责任公司 Traversal type use case verification method and system for chip simulation and electronic equipment
CN116775499A (en) * 2023-08-21 2023-09-19 中国电信股份有限公司 Test data generation method, device, computer equipment and storage medium
CN117453576A (en) * 2023-12-25 2024-01-26 企迈科技有限公司 DXM model-based SaaS software test case construction method

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2019510215A (en) * 2016-06-06 2019-04-11 三菱電機株式会社 Method and sensor system for estimating the state of charge of a battery
JP2018049492A (en) * 2016-09-23 2018-03-29 富士通株式会社 Analysis device, analysis program and analysis method
JP2019075035A (en) * 2017-10-19 2019-05-16 株式会社日立製作所 Software test device and method
CN110399286B (en) * 2018-04-24 2023-05-12 西安邮电大学 Independent path-based automatic test data generation method
CN110399286A (en) * 2018-04-24 2019-11-01 西安邮电大学 A kind of automatic generation of test data based on independent pathway
KR20210023130A (en) * 2019-08-22 2021-03-04 성균관대학교산학협력단 Method and system for Data caching based on In-Memory data processing framework, and recoding medium therefor
KR102258456B1 (en) 2019-08-22 2021-06-01 성균관대학교산학협력단 Method and system for Data caching based on In-Memory data processing framework, and recoding medium therefor
KR102130016B1 (en) * 2019-09-03 2020-07-03 성균관대학교산학협력단 Method and system for compiling for automatic caching, and recoding medium therefor
CN110795352A (en) * 2019-10-29 2020-02-14 中国科学院微小卫星创新研究院 Establishing and using method of fine-grained test case system for component-oriented star software
CN110795352B (en) * 2019-10-29 2024-02-27 中国科学院微小卫星创新研究院 Method for establishing and using fine granularity test case system for structured star software
CN114996076A (en) * 2022-07-01 2022-09-02 北京联盛德微电子有限责任公司 Traversal type use case verification method and system for chip simulation and electronic equipment
CN116775499A (en) * 2023-08-21 2023-09-19 中国电信股份有限公司 Test data generation method, device, computer equipment and storage medium
CN117453576A (en) * 2023-12-25 2024-01-26 企迈科技有限公司 DXM model-based SaaS software test case construction method
CN117453576B (en) * 2023-12-25 2024-04-09 企迈科技有限公司 DXM model-based SaaS software test case construction method

Similar Documents

Publication Publication Date Title
JP2016115175A (en) Software test apparatus and software test program
CN105701008B (en) System and method for test case generation
US10025696B2 (en) System and method for equivalence class analysis-based automated requirements-based test case generation
US9792204B2 (en) System and method for coverage-based automated test case augmentation for design models
BR102016018127A2 (en) design method based on critical security software model
US10733520B2 (en) Making a prediction regarding development of a software product
US10372584B2 (en) Software inspection apparatus
EP3264274A1 (en) Input discovery for unknown program binaries
González et al. Test data generation for model transformations combining partition and constraint analysis
US10037264B2 (en) Test suite minimization
JP2018055676A (en) Automatic software program repair
Weber et al. Mining processes with multi-instantiation
JP2013222327A (en) Software verification device and software verification program
JP6451417B2 (en) Debug support device, debug support system, debug support method, and debug support program
JP2009134360A (en) Model inspection system, model inspection method, and model inspection program
JP5755861B2 (en) Test case generation apparatus, test case generation method, and test case generation program
US10585779B2 (en) Systems and methods of requirements chaining and applications thereof
JP2017151594A (en) Supporting device, supporting method, and program
JP2015197868A (en) Computer program checking apparatus
Kumar et al. Software quality modeling using metrics of early artifacts
Namihira et al. Visualization Method to Stimulate Ideas Leading to Failure Mode in Software FMEA
JP6362970B2 (en) Compiling method, compiling device, and compiler program
JPWO2017104571A1 (en) Information processing apparatus, information processing method, and computer program
JPWO2016079962A1 (en) Model checking device, model checking method, and model checking program
JP6497271B2 (en) Test data generation apparatus, method, and program