JP2016071400A - Test execution device, test execution method, and computer program - Google Patents

Test execution device, test execution method, and computer program Download PDF

Info

Publication number
JP2016071400A
JP2016071400A JP2014196492A JP2014196492A JP2016071400A JP 2016071400 A JP2016071400 A JP 2016071400A JP 2014196492 A JP2014196492 A JP 2014196492A JP 2014196492 A JP2014196492 A JP 2014196492A JP 2016071400 A JP2016071400 A JP 2016071400A
Authority
JP
Japan
Prior art keywords
test
log
start time
time
unit
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
JP2014196492A
Other languages
Japanese (ja)
Inventor
勇人 高畠
Isato Takahata
勇人 高畠
翔 畠中
Sho Hatanaka
翔 畠中
森 一樹
Kazuki Mori
一樹 森
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.)
Nomura Research Institute Ltd
Original Assignee
Nomura Research Institute Ltd
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 Nomura Research Institute Ltd filed Critical Nomura Research Institute Ltd
Priority to JP2014196492A priority Critical patent/JP2016071400A/en
Publication of JP2016071400A publication Critical patent/JP2016071400A/en
Pending legal-status Critical Current

Links

Images

Abstract

PROBLEM TO BE SOLVED: To streamline log verification in an operational test of a system.SOLUTION: A test execution device 10 is for testing a test target system. The test execution device 10 includes: a time acquisition unit 22 that acquires a test start time; a test execution unit 23 that starts automatic execution of a test on the test target system 12 at the test start time; a log file acquisition unit 26 that acquires a log file that has been updated since the test start time from the system after completion of the test; a log extraction unit 27 that extracts a log that has been generated since the test start time from the acquired log file; a verification unit 29 that verifies whether or not a portion of the acquired log file excluding elements which values are determined at the execution of the test matches a predetermined expected value; and a verification result recording unit 30 that records a verification result in a verification result retaining unit 47.SELECTED DRAWING: Figure 2

Description

本発明はデータ処理技術に関し、特に情報システムをテストする技術に関する。   The present invention relates to a data processing technique, and more particularly to a technique for testing an information system.

情報システムの品質を保証する上で、サービス開始前の動作テストは不可欠である。例えば、情報システムの開発者が情報システムのユーザインタフェースを手動操作し、その操作結果を確認することにより動作テストを実行することが多い。しかし、操作のバリエーションが豊富な近年の情報システムでは、手動による動作テストには限界がある。   In order to guarantee the quality of the information system, operational tests before starting the service are indispensable. For example, an information system developer often performs an operation test by manually operating a user interface of the information system and confirming the operation result. However, in recent information systems with abundant operation variations, manual operation tests are limited.

本出願人は、情報システムの動作テストを自動化し、効率的な動作テストを実現するための技術を提案している(例えば特許文献1参照)。   The present applicant has proposed a technique for automating an operation test of an information system and realizing an efficient operation test (see, for example, Patent Document 1).

国際公開第2010/116586号International Publication No. 2010/116586

動作テストでは、結果検証のひとつとして、システムの各装置のログや装置上で動作する各アプリケーションのログを確認し、装置やアプリケーションの動作が想定通りであるかを検証する。具体的には、ログの内容が、予め期待されている値と一致するかを検証する。しかし、ログには、例えばログが出力されたタイムスタンプなど可変の要素が含まれる場合がある。例えば回帰テストにて取得したログを検証する際に、この可変要素も含めて検証されると、検証結果が不一致となる。そのため、従来は、こうした可変要素を手作業で取り除いてから期待値と一致するかを検証していた。この、作業は、テスト担当者の大きな負担となっていた。   In the operation test, as one result verification, a log of each device of the system and a log of each application operating on the device are checked to verify whether the operation of the device or application is as expected. Specifically, it is verified whether or not the content of the log matches a value expected in advance. However, the log may include variable elements such as a time stamp when the log is output. For example, when verifying a log acquired by a regression test including verification of this variable element, the verification results are inconsistent. For this reason, conventionally, after verifying whether or not the variable elements coincide with the expected value after manually removing such variable elements. This work was a heavy burden on the test personnel.

本発明はこうした課題に鑑みてなされたものであり、その主な目的は、システムの動作テストにおけるログの検証を効率化するための技術を提供することにある。   The present invention has been made in view of these problems, and a main object thereof is to provide a technique for improving the efficiency of log verification in a system operation test.

上記課題を解決するために、本発明のある態様のテスト実行装置は、システムをテストする装置であって、テスト開始時刻を取得する時刻取得部と、テスト開始時刻からシステムのテストの自動実行を開始するテスト実行部と、テスト開始時刻以降に更新されたログファイルをテストの終了後にシステムから取得する取得部と、取得されたログファイルから、テスト開始時刻以降に出力されたログを抽出するログ抽出部と、抽出されたログから、テスト実行時に値が決まる要素を除いた部分が、所定の期待値と一致するか否かを検証する検証部と、を備える。   In order to solve the above problems, a test execution device according to an aspect of the present invention is a device for testing a system, and includes a time acquisition unit that acquires a test start time, and automatic execution of the system test from the test start time. The test execution unit to start, the acquisition unit that acquires the log file updated after the test start time from the system after the test ends, and the log that extracts the log output after the test start time from the acquired log file An extraction unit; and a verification unit that verifies whether or not a portion obtained by removing an element whose value is determined at the time of test execution from the extracted log matches a predetermined expected value.

本発明の別の態様は、テスト実行方法である。この方法は、システムをテストする装置において実行される方法であって、テスト開始時刻を取得するステップと、テスト開始時刻からシステムのテストの自動実行を開始するステップと、テスト開始時刻以降に更新されたログファイルをテストの終了後にシステムから取得するステップと、取得されたログファイルから、テスト開始時刻以降に出力されたログを抽出するステップと、抽出されたログから、テスト実行時に値が決まる要素を除いた部分が、所定の期待値と一致するか否かを検証するステップと、を含む。   Another aspect of the present invention is a test execution method. This method is executed in an apparatus for testing a system, and is updated after a step of obtaining a test start time, a step of starting automatic execution of a system test from the test start time, and a test start time or later. To acquire the log file from the system after the test is completed, to extract the log output after the test start time from the acquired log file, and the element whose value is determined at the time of test execution from the extracted log Verifying whether or not the portion excluding is coincident with a predetermined expected value.

なお、以上の構成要素の任意の組合せ、本発明の表現を、システム、プログラム、プログラムを格納した記録媒体などの間で変換したものもまた、本発明の態様として有効である。   Note that any combination of the above-described constituent elements and the expression of the present invention converted between a system, a program, a recording medium storing the program, and the like are also effective as an aspect of the present invention.

本発明によれば、システムの動作テストにおけるログの検証を効率化するための技術を提供できる。   According to the present invention, it is possible to provide a technique for improving the efficiency of log verification in a system operation test.

実施の形態に係るテストシステムの構成を示す図である。It is a figure which shows the structure of the test system which concerns on embodiment. 図1のテスト実行装置の機能構成を示すブロック図である。It is a block diagram which shows the function structure of the test execution apparatus of FIG. 更新時刻保持部のデータ構造を示す図である。It is a figure which shows the data structure of an update time holding | maintenance part. 取得対象一覧保持部のデータ構造を示す図である。It is a figure which shows the data structure of an acquisition object list holding part. ログファイルに出力されたログの一例を示す図である。It is a figure which shows an example of the log output to the log file. 整形ログファイルに出力された整形ログの一例を示す図である。It is a figure which shows an example of the shaping log output to the shaping log file.

図1は、テストシステム100の構成を示す。テストシステム100は、テスト実行装置10と、テスト対象システム12と、を含む。テスト対象システム12は、テストの対象となるシステムであり、ウェブアプリケーションサーバ14を備える。テスト対象システム12は、不図示のメインフレームや帳票サーバやデータベースサーバ等、種々のサーバや装置をさらに備えてもよく、これらの装置が連携することにより各種の情報処理サービスを実現してもよい。   FIG. 1 shows the configuration of the test system 100. The test system 100 includes a test execution device 10 and a test target system 12. The test target system 12 is a system to be tested and includes a web application server 14. The test target system 12 may further include various servers and devices such as a mainframe (not shown), a form server, and a database server, and various information processing services may be realized by cooperation of these devices. .

ウェブアプリケーションサーバ14は、テスト対象システムによる各種の情報処理サービスをクライアント装置へ提供する。実施の形態では、ウェブアプリケーションサーバ14は、クライアント装置に対してウェブページを提供し、そのウェブページに対して入力された情報をクライアント装置から取得して業務処理を実行する。変形例として、ウェブページに限らず、クライアント装置が専用のクライアント画面を表示させ、その画面への入力情報をクライアント装置がテスト対象システム12へ送信し、テスト対象システム12が業務処理を実行してもよい。   The web application server 14 provides various information processing services by the test target system to the client device. In the embodiment, the web application server 14 provides a web page to the client device, acquires information input to the web page from the client device, and executes business processing. As a modified example, not only a web page but also a client device displays a dedicated client screen, the client device transmits input information to the screen to the test target system 12, and the test target system 12 executes business processing. Also good.

テスト実行装置10は、テスト対象システム12のテストを実行する情報処理装置である。具体的には、テスト実行装置10は、テスト対象システム12のクライアント装置として動作し、LAN・WAN・インターネット等の通信網を介して、業務イベント情報をテスト対象システム12へ入力することによりテスト対象システム12の動作を検証する。   The test execution device 10 is an information processing device that executes a test of the test target system 12. Specifically, the test execution device 10 operates as a client device of the test target system 12 and inputs the business event information to the test target system 12 via a communication network such as a LAN, WAN, or the Internet. The operation of the system 12 is verified.

テスト実行装置10は、ウェブアプリケーションサーバ14からウェブページを取得し、そのウェブページに対して予め定められた操作を再現することでテスト対象システム12の動作テストを実行する。またテスト実行装置10は、動作テストの結果検証のひとつとして、テスト対象システム12の各装置のログや装置上で動作する各アプリケーションのログを確認し、装置やアプリケーションの動作が想定通りであるかを検証する。   The test execution device 10 acquires a web page from the web application server 14, and executes an operation test of the test target system 12 by reproducing a predetermined operation on the web page. Further, as one result verification of the operation test, the test execution device 10 confirms the log of each device of the test target system 12 and the log of each application operating on the device, and whether the operation of the device or application is as expected. To verify.

実施の形態では、テスト実行装置10は、ウェブアプリケーションサーバ14が出力する第1ログファイル16a(system.log)、第2ログファイル16b(error.log)と、ウェブアプリケーションサーバ14上で動作するアプリケーションが出力する第3ログファイル16c(apl01.log)、第4ログファイル16d(apl02.log)を保持しており、テスト実行装置10は、このうち検証の必要があるログファイルだけを取得する。検証の必要があるログファイルの判断方法については後述する。以下、第1ログファイル16a、第2ログファイル16b、第3ログファイル16c、第4ログファイル16dをまとめて「ログファイル16」と呼ぶ。   In the embodiment, the test execution device 10 includes a first log file 16a (system.log) and a second log file 16b (error.log) output from the web application server 14, and an application operating on the web application server 14. The third log file 16c (apl01.log) and the fourth log file 16d (apl02.log) output are stored, and the test execution device 10 acquires only the log files that need to be verified. A method for determining a log file that needs to be verified will be described later. Hereinafter, the first log file 16a, the second log file 16b, the third log file 16c, and the fourth log file 16d are collectively referred to as “log file 16”.

取得したログファイル16には、例えばログが出力された時刻を示すタイムスタンプなど、テスト実行時に値が決まる要素(別の言い方をすると、予め期待される値を決定することができない要素)が含まれる。テスト実行装置10は、ログファイル16のログからこうした要素を削除したログ(以下、「整形ログ」と呼ぶ)を作成する。一方で、テスト実行装置10は、動作テストを実施したときにログファイル16に出力されると期待されるログ(以下、「期待値ログ」と呼ぶ)が書き込まれた期待値ログファイルを保持する。実施の形態では、テスト実行装置10は、第1ログファイル16aに対応する第1期待値ログファイル18a(system_kitai.log)と、第3ログファイル16c(apl01_kitai.log)に対応する第3期待値ログファイル18cと、を保持している。テスト実行装置10は、整形ログと期待値ログとが一致するかを検証する。一致していればテスト結果が正常と判定し、一致していなければテスト結果が異常と判定する。   The acquired log file 16 includes elements whose values are determined at the time of test execution (in other words, elements that cannot be expected in advance), such as a time stamp indicating the time when the log is output. It is. The test execution device 10 creates a log (hereinafter referred to as “shaped log”) in which such elements are deleted from the log of the log file 16. On the other hand, the test execution device 10 holds an expected value log file in which a log (hereinafter referred to as “expected value log”) that is expected to be output to the log file 16 when an operation test is performed is written. . In the embodiment, the test execution device 10 includes the first expected value log file 18a (system_kitai.log) corresponding to the first log file 16a and the third expected value corresponding to the third log file 16c (apl01_kitai.log). Log file 18c. The test execution device 10 verifies whether the shaping log matches the expected value log. If they match, the test result is determined to be normal, and if they do not match, the test result is determined to be abnormal.

図2は、図1のテスト実行装置10の構成を示すブロック図である。テスト実行装置10は、制御部20とデータ記録部40を備える。制御部20は、テスト実行装置10の動作を制御し、また、テスト対象システム12のテストに係る各種データ処理を実行する。データ記録部40は、制御部20によるデータ処理において参照、更新される各種データを記憶する記憶領域である。図2には不図示だが、テスト実行装置10には、所定のウェブブラウザプログラムがインストールされている。   FIG. 2 is a block diagram showing a configuration of the test execution device 10 of FIG. The test execution device 10 includes a control unit 20 and a data recording unit 40. The control unit 20 controls the operation of the test execution device 10 and executes various data processing related to the test of the test target system 12. The data recording unit 40 is a storage area for storing various data that are referred to and updated in the data processing by the control unit 20. Although not shown in FIG. 2, a predetermined web browser program is installed in the test execution device 10.

本明細書のブロック図で示す各ブロックは、ハードウェア的には、コンピュータのCPUやメモリをはじめとする素子や機械装置で実現でき、ソフトウェア的にはコンピュータプログラム等によって実現されるが、ここでは、それらの連携によって実現される機能ブロックを描いている。したがって、これらの機能ブロックはハードウェア、ソフトウェアの組合せによっていろいろなかたちで実現できることは、当業者には理解されるところである。例えば、制御部20の各機能ブロックに対応するソフトウェアモジュールを備えるテスト自動実行アプリケーションがテスト実行装置10にインストールされてもよい。そして、テスト実行装置10のCPUが、各ソフトウェアモジュールをメモリに読み出して実行することにより、制御部20の各機能ブロックの機能が発揮されてもよい。また、データ記録部40の各機能ブロックは、ストレージやメモリ等の記憶装置がデータを記憶することにより実現されてもよい。   Each block shown in the block diagram of the present specification can be realized in terms of hardware by an element such as a CPU and a memory of a computer or a mechanical device, and in terms of software, it can be realized by a computer program or the like. , Depicts functional blocks realized by their cooperation. Therefore, those skilled in the art will understand that these functional blocks can be realized in various forms by a combination of hardware and software. For example, an automatic test execution application including a software module corresponding to each functional block of the control unit 20 may be installed in the test execution device 10. Then, the function of each functional block of the control unit 20 may be exhibited by the CPU of the test execution device 10 reading out and executing each software module in the memory. Each functional block of the data recording unit 40 may be realized by storing data in a storage device such as a storage or a memory.

データ記録部40は、開始時刻保持部41、更新時刻保持部42、取得対象一覧保持部43、ログファイル保持部44、整形ログファイル保持部45、期待値ログファイル保持部46、検証結果保持部47を含む。   The data recording unit 40 includes a start time holding unit 41, an update time holding unit 42, an acquisition target list holding unit 43, a log file holding unit 44, a shaped log file holding unit 45, an expected value log file holding unit 46, and a verification result holding unit. 47.

開始時刻保持部41は、動作テストを開始した時刻を「テスト開始時刻」として保持する。更新時刻保持部42は、動作テストの完了後における、テスト対象システム12の各種ログファイルの更新時刻を保持する。図3は、更新時刻保持部42のデータ構造を示す。更新時刻保持部42は、各種ログファイルのログファイル名120と、その更新時刻122とを対応付けて保持する。ここでは、テスト対象システム12は、「system.log(第1ログファイル16a)」、「error.log(第2ログファイル16b)」、「apl01.log(第3ログファイル16c)」、「apl02.log(第4ログファイル16d)」の4つのログファイルを保持している。図2に戻る。   The start time holding unit 41 holds the time when the operation test is started as “test start time”. The update time holding unit 42 holds update times of various log files of the test target system 12 after the operation test is completed. FIG. 3 shows the data structure of the update time holding unit 42. The update time holding unit 42 holds the log file names 120 of various log files and the update time 122 in association with each other. Here, the test target system 12 includes "system.log (first log file 16a)", "error.log (second log file 16b)", "apl01.log (third log file 16c)", "apl02 .log (fourth log file 16d) ". Returning to FIG.

取得対象一覧保持部43は、テスト対象システム12の各種ログファイルのうち、動作テストの結果検証として検証する必要があるログファイルの一覧、すなわちテスト実行装置10が取得するべきログファイルの一覧を保持する。図4は、取得対象一覧保持部43のデータ構造を示す。取得対象一覧保持部43は、取得するべきログファイルのログファイル名124を保持する。ここでは、テスト対象システム12が保持する4つのログファイルのうち、「system.log(第1ログファイル16a)」「apl01.log(第3ログファイル16c)」が、取得すべきログファイルとされている。   The acquisition target list holding unit 43 holds a list of log files that need to be verified as a result verification of the operation test among various log files of the test target system 12, that is, a list of log files that the test execution apparatus 10 should acquire. To do. FIG. 4 shows the data structure of the acquisition target list holding unit 43. The acquisition target list holding unit 43 holds the log file name 124 of the log file to be acquired. Here, among the four log files held by the test target system 12, “system.log (first log file 16a)” and “apl01.log (third log file 16c)” are log files to be acquired. ing.

ログファイル保持部44は、テスト対象システム12から取得したログファイルを保持する。図5は、ログファイル保持部44に保持されるログファイルに出力されたログの一例を示す。同図に示すログは、デリミタ文字列が「 」(スペース)であり、ログが出力された時刻を示す「タイムスタンプ102」、業務を行っている「ユーザID104」、リクエスト単位でユニークに設定される「リクエストID106」、ログ出力を行うサーバの「ホスト名108」、呼び出し先の「クラス名110」、呼び出し先の「メソッド名112」、「メッセージ本文114」を含む。   The log file holding unit 44 holds a log file acquired from the test target system 12. FIG. 5 shows an example of the log output to the log file held in the log file holding unit 44. The log shown in the figure has a delimiter character string “” (space), “time stamp 102” indicating the time when the log was output, “user ID 104” performing business, and uniquely set for each request. “Request ID 106”, “host name 108” of the server that performs log output, “class name 110” of the call destination, “method name 112” of the call destination, and “message body 114”.

整形ログファイル保持部45は、整形ログが書き込まれた整形ログファイルを保持する。図6は、整形ログファイルに出力された整形ログの一例を示す。図6は、図5の点線で囲まれたログの整形ログに対応する。同図の整形ログには、業務を行っているユーザID104、呼び出し先のクラス名110、呼び出し先のメソッド名112、メッセージ本文114が含まれる。つまり、図6のログから、ログが出力された時刻を示すタイムスタンプ102、リクエスト単位でユニークに設定されるリクエストID106、ログ出力を行うサーバのホスト名108が取り除かれている。   The shaping log file holding unit 45 holds the shaping log file in which the shaping log is written. FIG. 6 shows an example of the shaping log output to the shaping log file. FIG. 6 corresponds to a log shaping log surrounded by a dotted line in FIG. The shaping log in FIG. 5 includes a user ID 104 who performs business, a callee class name 110, a callee method name 112, and a message body 114. That is, the time stamp 102 indicating the time when the log is output, the request ID 106 uniquely set for each request, and the host name 108 of the server that performs log output are removed from the log of FIG.

期待値ログファイル保持部46は、期待値ログが書き込まれた期待値ログファイルを保持する。期待値ログファイルは、テスト担当者によって動作テストの開始前に作成される。テスト担当者は、過去に同様の動作テストを行ったときに出力されたログを基に期待値ログファイルを作成してもよい。例えば動作テストにより、テスト対象システム12が保持する4つのログファイルのうちの「system.log(第1ログファイル16a)」、「apl01.log(第3ログファイル16c)」にログが出力されると期待される場合は、これらに対応する期待値ログファイル「system_kitai.log(第1期待値ログファイル18a)」、「apl01_kitai.log(第3期待値ログファイル18c)」を作成しておく。期待値ログのデータ構造は、整形ログのデータ構造と同様である。   The expected value log file holding unit 46 holds the expected value log file in which the expected value log is written. The expected value log file is created by the tester before starting the operation test. The person in charge of the test may create an expected value log file based on a log output when a similar operation test is performed in the past. For example, a log is output to “system.log (first log file 16a)” and “apl01.log (third log file 16c)” out of four log files held by the test target system 12 by an operation test. Are expected, log files “system_kitai.log (first expected value log file 18a)” and “apl01_kitai.log (third expected value log file 18c)” corresponding to these are created in advance. The data structure of the expected value log is the same as the data structure of the shaping log.

検証結果保持部47は、整形ログと期待値ログとが一致するかを検証した結果を示す検証結果情報を保持する。例えば、動作テストの内容を一意に特定するテストケースIDと、期待値ログファイルのファイル名と、期待値ログの内容と、整形ログファイルのファイル名と、整形ログの内容と、検証結果(正常・異常の判定結果)を検証結果情報として保持する。   The verification result holding unit 47 holds verification result information indicating a result of verifying whether the shaping log matches the expected value log. For example, the test case ID that uniquely identifies the content of the behavior test, the file name of the expected value log file, the content of the expected value log, the file name of the shaped log file, the content of the shaped log, and the verification result (normal・ Abnormal judgment result) is held as verification result information.

制御部20は、操作検出部21、時刻取得部22、テスト実行部23、更新時刻取得部24、取得対象一覧作成部25、ログファイル取得部26、ログ抽出部27、ログ整形部28、検証部29、検証結果記録部30、検証結果提供部31を含む。操作検出部21は、キーボードやマウス等の入力装置に対してユーザが入力した操作を検出する。   The control unit 20 includes an operation detection unit 21, a time acquisition unit 22, a test execution unit 23, an update time acquisition unit 24, an acquisition target list creation unit 25, a log file acquisition unit 26, a log extraction unit 27, a log shaping unit 28, a verification Unit 29, verification result recording unit 30, and verification result providing unit 31. The operation detection unit 21 detects an operation input by the user with respect to an input device such as a keyboard or a mouse.

時刻取得部22は、テストの実行を指示する操作が入力された場合に、テスト対象システム12のシステム時刻を取得する。時刻取得部22は、これを「テスト開始時刻」として開始時刻保持部41に記録する。   The time acquisition unit 22 acquires the system time of the test target system 12 when an operation for instructing execution of the test is input. The time acquisition unit 22 records this as the “test start time” in the start time holding unit 41.

テスト実行部23は、時刻取得部22がシステム時刻を取得すると、テスト対象システム12に対する自動テストを開始する。テスト実行部23は、所定のURLをウェブブラウザに渡す。ウェブブラウザは、そのURLで特定される操作対象のウェブページをウェブアプリケーションサーバ14から取得し、表示装置に表示させる。テスト実行部23は、所定の操作を、ウェブブラウザが表示するウェブページに対して実行する。ウェブページに対する操作は、先行技術文献1に示す方法等、公知の方法を使用してよい。   When the time acquisition unit 22 acquires the system time, the test execution unit 23 starts an automatic test for the test target system 12. The test execution unit 23 passes a predetermined URL to the web browser. The web browser acquires the operation target web page specified by the URL from the web application server 14 and displays it on the display device. The test execution unit 23 performs a predetermined operation on the web page displayed by the web browser. For the operation on the web page, a known method such as the method described in Prior Art Document 1 may be used.

更新時刻取得部24は、テスト実行部23による動作テストが完了したことを検出すると、テスト対象システム12の各種ログファイルの更新時刻を取得する。更新時刻取得部24は、各種ログファイルのログファイル名と、その更新時刻とを対応付けて更新時刻保持部42に記録する。   When the update time acquisition unit 24 detects that the operation test by the test execution unit 23 is completed, the update time acquisition unit 24 acquires update times of various log files of the test target system 12. The update time acquisition unit 24 records the log file names of various log files and their update times in the update time holding unit 42 in association with each other.

取得対象一覧作成部25は、検証対象として取得するべきログファイルの一覧を作成する。具体的には、取得対象一覧作成部25は、開始時刻保持部41と更新時刻保持部42とを参照して、更新時刻がテスト開始時刻よりも新しいログファイルの一覧を作成する。つまり、更新時刻がテスト開始時刻よりも新しいログファイルには動作テスト時のログが出力されているため、取得対象一覧作成部25は、それらを取得すべきログファイルとして一覧に含める。取得対象一覧作成部25は、作成した一覧を取得対象一覧保持部43に記録する。例えばテスト開始時刻が「2014-03-23 14:25:38.150」の場合、図3の例では、「system.log」、「apl01.log」の更新時刻がテスト開始時刻より新しいため、これらが取得すべきファイルとされる。   The acquisition target list creation unit 25 creates a list of log files to be acquired as verification targets. Specifically, the acquisition target list creating unit 25 refers to the start time holding unit 41 and the update time holding unit 42 and creates a list of log files whose update time is newer than the test start time. That is, since the log at the time of the operation test is output to the log file whose update time is later than the test start time, the acquisition target list creation unit 25 includes them in the list as log files to be acquired. The acquisition target list creation unit 25 records the created list in the acquisition target list holding unit 43. For example, if the test start time is “2014-03-23 14: 25: 38.150”, the update time of “system.log” and “apl01.log” is newer than the test start time in the example of FIG. The file to be acquired.

ログファイル取得部26は、取得対象一覧保持部43を参照して、その一覧に含まれるログファイルをテスト対象システム12から取得する。ログファイル取得部26は、取得したログファイルをログファイル保持部44に格納する。   The log file acquisition unit 26 refers to the acquisition target list holding unit 43 and acquires log files included in the list from the test target system 12. The log file acquisition unit 26 stores the acquired log file in the log file holding unit 44.

ログ抽出部27は、ログファイルに出力されたログから、検証対象のログを抽出する。具体的には、ログ抽出部27は、ログファイル保持部44に保持されるログファイルに出力されたログの中からテスト開始時刻以降に書き込まれたログを抽出する。例えばテスト開始時刻が「2014-03-23 14:25:38.150」の場合、図3の例では、破線で囲まれたログが抽出される。   The log extraction unit 27 extracts a verification target log from the log output to the log file. Specifically, the log extraction unit 27 extracts logs written after the test start time from the logs output to the log file held in the log file holding unit 44. For example, when the test start time is “2014-03-23 14: 25: 38.150”, in the example of FIG. 3, a log surrounded by a broken line is extracted.

ログ整形部28は、ログ抽出部27により抽出されたログから、テスト実行時に値が決まる要素(別の言い方をすると、予め期待される値を決定することができない要素)を取り除いたログを作成する。実施の形態では、ログが出力された時刻を示すタイムスタンプ102、リクエストID106、ホスト名108が含まれない整形ログを作成する。なお、実施の形態ではログ整形部28はさらに、各要素を引用符で囲み、デリミタ文字列を「,」(カンマ)に変換する。ログ整形部28は、作成した整形ログを整形ログファイルに出力し、これを整形ログファイル保持部45に格納する。   The log shaping unit 28 creates a log from the log extracted by the log extraction unit 27 by removing elements whose values are determined at the time of test execution (in other words, elements that cannot be expected in advance) To do. In the embodiment, a shaping log that does not include the time stamp 102 indicating the time when the log is output, the request ID 106, and the host name 108 is created. In the embodiment, the log shaping unit 28 further encloses each element in quotation marks and converts the delimiter character string into “,” (comma). The log shaping unit 28 outputs the created shaping log to a shaping log file and stores it in the shaping log file holding unit 45.

検証部29は、整形ログファイルに出力された整形ログと、それに対応する期待値ログファイルに書き込まれている期待値ログとが一致するか否かを検証する。検証部29は、両者が一致する場合、テスト結果が正常と判定する。その一方、両者が不一致の場合、テスト結果が異常と判定する。なお、不一致のケースとしては、出力されるべきログが出力されていないケース、出力されているログの内容が期待と異なるケース、出力されることが期待されていないログが出力されているケース、が考えられる。出力されることが期待されていないログが出力されているケースの代表例としては、想定しないエラーに関するログが出力されている場合が挙げられる。   The verifying unit 29 verifies whether the shaped log output to the shaped log file matches the expected value log written in the corresponding expected value log file. The verification unit 29 determines that the test result is normal when the two match. On the other hand, if the two do not match, the test result is determined to be abnormal. In addition, as a mismatch case, the log that should be output is not output, the content of the output log is different from the expectation, the log that is not expected to be output is output, Can be considered. A typical example of a case where a log that is not expected to be output is output is a case where a log regarding an unexpected error is output.

検証結果記録部30は、検証結果情報を検証結果保持部47へ記録する。検証結果提供部31は、検証結果の表示を指示する操作が入力された場合に、検証結果保持部47に保持された検証結果情報を表示装置に表示させる。例えば、検証結果が異常である場合は、期待値ログと整形ログとの不一致部分を強調して表示してもよい。また、想定しないエラーに関するログが出力されている場合は、特に強調して表示してもよい。   The verification result recording unit 30 records verification result information in the verification result holding unit 47. The verification result providing unit 31 causes the display device to display verification result information held in the verification result holding unit 47 when an operation for instructing display of the verification result is input. For example, when the verification result is abnormal, the mismatched portion between the expected value log and the shaped log may be highlighted and displayed. Further, when a log regarding an unexpected error is output, the log may be particularly emphasized.

以上の構成によるテスト時の動作を以下説明する。
テスト担当者は、テスト開始指示をテスト実行装置10へ入力する。時刻取得部22はテスト対象システム12からシステム時刻を取得し、それをテスト開始時刻とする。テスト実行部23は、テスト対象システム12の動作テストを実行する。
The operation during the test with the above configuration will be described below.
The person in charge of the test inputs a test start instruction to the test execution device 10. The time acquisition unit 22 acquires the system time from the test target system 12 and sets it as the test start time. The test execution unit 23 executes an operation test of the test target system 12.

更新時刻取得部24は、テスト実行部23による動作テストが完了したことを検出すると、テスト対象システム12の各種ログファイルの更新時刻を取得する。取得対象一覧作成部25は、それら各種ログファイルのうち、更新時刻がテスト開始時刻よりも新しいログファイルを取得対象として決定し、ログファイル取得部26が決定されたログファイルを取得する。   When the update time acquisition unit 24 detects that the operation test by the test execution unit 23 is completed, the update time acquisition unit 24 acquires update times of various log files of the test target system 12. The acquisition target list creation unit 25 determines a log file whose update time is newer than the test start time among the various log files as an acquisition target, and the log file acquisition unit 26 acquires the determined log file.

検証部29は、ログファイルに出力されたログからテスト開始時刻以降に書き込まれたログを抽出し、それから整形ログを作成する。検証部29は、整形ログが、期待値ログと一致するかを検証する。一致する場合はテスト結果が正常と判定し、不一致の場合は異常と判定する。検証結果提供部31は、ユーザの要求に応じて、検証結果情報を表示装置に表示させる。   The verification unit 29 extracts a log written after the test start time from the log output to the log file, and creates a shaping log therefrom. The verification unit 29 verifies whether the shaping log matches the expected value log. If they match, the test result is determined to be normal, and if they do not match, it is determined to be abnormal. The verification result providing unit 31 displays verification result information on the display device in response to a user request.

実施の形態のテスト実行装置10によると、更新時刻がテスト開始時刻以降のログがテスト対象システム12から取得される。すなわち、動作テストの実行時にログが出力されたログファイルだけがテスト対象システム12から取得される。このため、例えばテスト対象システム12が保持するすべてのログファイルを取得する場合など、検証する必要のないログファイルまでも取得する場合に比べ、ログファイルの取得に掛かる時間が短縮され、効率的な動作テストを実現できる。   According to the test execution device 10 of the embodiment, a log whose update time is after the test start time is acquired from the test target system 12. That is, only the log file to which a log is output when the operation test is executed is acquired from the test target system 12. For this reason, for example, when all log files held by the test target system 12 are acquired, the time required to acquire the log file is shortened compared to the case where even the log file that does not need to be verified is acquired. Operation test can be realized.

また、テスト実行装置10によると、ログファイルに出力されたログから、テスト開始時刻以降に出力されたログが抽出される。そのため、ログファイルに出力されたすべてのログを検証対象とする場合に比べ、検証にかかる時間を短縮でき、効率的な動作テストを実現できる。   In addition, according to the test execution device 10, logs output after the test start time are extracted from the logs output to the log file. Therefore, the time required for verification can be shortened and an efficient operation test can be realized as compared with the case where all the logs output to the log file are to be verified.

また、テスト実行装置10によると、ログが出力された時刻を示すタイムスタンプなど、テスト実行時に値が決まる要素(別の言い方をすると、予め期待される値を決定することができない要素)が取り除かれた整形ログが作成される。そのため、テスト担当者がこのような要素を手作業で取り除く必要がなくなり、ログの検証も含めて動作テストを自動で実行することが可能となる。これにより、作業者の負担が軽減される。加えて、効率的な動作テストを実現できる。   In addition, according to the test execution device 10, elements whose values are determined at the time of test execution (in other words, elements that cannot be expected in advance) such as a time stamp indicating the time when the log is output are removed. A formatted log is created. This eliminates the need for a tester to manually remove such elements, and allows an operation test to be automatically executed including log verification. This reduces the burden on the operator. In addition, an efficient operation test can be realized.

また、テスト実行装置10によると、動作テストの実行を開始する際のテスト対象システム12のシステム時刻をテスト開始時刻として取得する。そのため、例えばテスト実行装置10とテスト対象システム12とでシステム時刻がずれていても、適確に取得するべきログを取得でき、また抽出するべきログを抽出できる。   Further, according to the test execution device 10, the system time of the test target system 12 when the execution of the operation test is started is acquired as the test start time. Therefore, for example, even if the system time is shifted between the test execution device 10 and the test target system 12, it is possible to acquire a log to be acquired properly and to extract a log to be extracted.

以上、本発明を実施の形態をもとに説明した。この実施の形態は例示であり、それらの各構成要素や各処理プロセスの組合せにいろいろな変形例が可能なこと、またそうした変形例も本発明の範囲にあることは当業者に理解されるところである。   The present invention has been described based on the embodiments. This embodiment is an exemplification, and it will be understood by those skilled in the art that various modifications can be made to combinations of the respective constituent elements and processing processes, and such modifications are also within the scope of the present invention. is there.

実施の形態では、特に触れなかったが、整形ログに含める要素を指定できるようにしてもよい。例えば、ログ整形部28が、ログファイルに出力されたログのデリミタ文字列の指定と整形ログに含める要素の位置の指定とを受け付け、これに基づいて整形ログを作成してもよい。例えば図5のログに対して、ログ整形部28がデリミタ文字列「 」(スペース)と要素位置「3列目、6列目、7列目、8列目」とを受け付けると、ログ整形部28は図6の整形ログを作成する。   Although not particularly mentioned in the embodiment, elements included in the shaping log may be designated. For example, the log shaping unit 28 may accept the designation of the delimiter character string of the log output to the log file and the designation of the position of the element to be included in the shaping log, and create the shaping log based on this. For example, when the log shaping unit 28 receives the delimiter character string “” (space) and the element position “third column, sixth column, seventh column, eighth column” for the log in FIG. 28 creates the shaping log of FIG.

請求項に記載の各構成要件が果たすべき機能は、実施の形態および変形例において示された各構成要素の単体もしくはそれらの連携によって実現されることも当業者には理解されるところである。   It should also be understood by those skilled in the art that the functions to be fulfilled by the constituent elements described in the claims are realized by the individual constituent elements shown in the embodiments and the modification examples or by their cooperation.

10 テスト実行装置、 12 テスト対象システム、 14 ウェブアプリケーションサーバ、 20 制御部、 21 操作検出部、 22 時刻取得部、 23 テスト実行部、 24 更新時刻取得部、 25 取得対象一覧作成部、 26 ログファイル取得部、 27 ログ抽出部、 28 ログ整形部、 29 検証部、 30 検証結果記録部、 31 検証結果提供部、 40 データ記録部、 41 開始時刻保持部、 42 更新時刻保持部、 43 取得対象一覧保持部、 44 ログファイル保持部、 45 整形ログファイル保持部、 46 期待値ログファイル保持部、 47 検証結果保持部、 100 テストシステム。   DESCRIPTION OF SYMBOLS 10 Test execution apparatus, 12 Test object system, 14 Web application server, 20 Control part, 21 Operation detection part, 22 Time acquisition part, 23 Test execution part, 24 Update time acquisition part, 25 Acquisition object list creation part, 26 Log file Acquisition unit, 27 log extraction unit, 28 log shaping unit, 29 verification unit, 30 verification result recording unit, 31 verification result providing unit, 40 data recording unit, 41 start time holding unit, 42 update time holding unit, 43 acquisition target list Holding unit, 44 log file holding unit, 45 shaped log file holding unit, 46 expected value log file holding unit, 47 verification result holding unit, 100 test system.

Claims (5)

システムをテストする装置であって、
テスト開始時刻を取得する時刻取得部と、
前記テスト開始時刻から前記システムのテストの自動実行を開始するテスト実行部と、
前記テスト開始時刻以降に更新されたログファイルをテストの終了後に前記システムから取得する取得部と、
取得されたログファイルから、前記テスト開始時刻以降に出力されたログを抽出するログ抽出部と、
抽出されたログから、テスト実行時に値が決まる要素を除いた部分が、所定の期待値と一致するか否かを検証する検証部と、
を備えることを特徴とするテスト実行装置。
A device for testing a system,
A time acquisition unit for acquiring a test start time;
A test execution unit for starting automatic execution of the test of the system from the test start time;
An acquisition unit for acquiring a log file updated after the test start time from the system after the end of the test;
A log extraction unit that extracts logs output after the test start time from the acquired log file;
A verification unit that verifies whether or not a part obtained by removing an element whose value is determined at the time of test execution from the extracted log matches a predetermined expected value;
A test execution device comprising:
前記テスト実行時に値が決まる要素には、少なくともログが出力された時刻に関する情報を含むことを特徴とする請求項1に記載のテスト実行装置。   The test execution apparatus according to claim 1, wherein the element whose value is determined at the time of the test execution includes at least information related to a time when the log is output. 前記時刻取得部は、前記システムのシステム時刻を取得することを特徴とする請求項1または2に記載のテスト実行装置。   The test execution device according to claim 1, wherein the time acquisition unit acquires a system time of the system. システムをテストする装置において実行される方法であって、
テスト開始時刻を取得するステップと、
前記テスト開始時刻から前記システムのテストの自動実行を開始するステップと、
前記テスト開始時刻以降に更新されたログファイルをテストの終了後に前記システムから取得するステップと、
取得されたログファイルから、前記テスト開始時刻以降に出力されたログを抽出するステップと、
抽出されたログから、テスト実行時に値が決まる要素を除いた部分が、所定の期待値と一致するか否かを検証するステップと、
を含むことを特徴とするテスト実行方法。
A method performed on an apparatus for testing a system, comprising:
Obtaining a test start time;
Starting automatic execution of the test of the system from the test start time;
Obtaining a log file updated after the test start time from the system after completion of the test;
Extracting the log output after the test start time from the acquired log file;
Verifying whether or not the portion of the extracted log excluding elements whose values are determined at the time of test execution matches a predetermined expected value;
A test execution method comprising:
システムをテストするテスト装置に、
テスト開始時刻を取得する機能と、
前記テスト開始時刻から前記システムのテストの自動実行を開始する機能と、
前記テスト開始時刻以降に更新されたログファイルをテストの終了後に前記システムから取得する機能と、
取得されたログファイルから、前記テスト開始時刻以降に出力されたログを抽出する機能と、
抽出されたログから、テスト実行時に値が決まる要素を除いた部分が、所定の期待値と一致するか否かを検証する機能と、
を実現させるためのコンピュータプログラム。
To test equipment to test the system,
The ability to get the test start time,
A function of starting automatic execution of the test of the system from the test start time;
A function to obtain a log file updated after the test start time from the system after the test is completed;
A function to extract logs output after the test start time from the acquired log file;
A function that verifies whether or not the part of the extracted log excluding the element whose value is determined at the time of test execution matches the predetermined expected value;
Computer program for realizing.
JP2014196492A 2014-09-26 2014-09-26 Test execution device, test execution method, and computer program Pending JP2016071400A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014196492A JP2016071400A (en) 2014-09-26 2014-09-26 Test execution device, test execution method, and computer program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014196492A JP2016071400A (en) 2014-09-26 2014-09-26 Test execution device, test execution method, and computer program

Publications (1)

Publication Number Publication Date
JP2016071400A true JP2016071400A (en) 2016-05-09

Family

ID=55866950

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014196492A Pending JP2016071400A (en) 2014-09-26 2014-09-26 Test execution device, test execution method, and computer program

Country Status (1)

Country Link
JP (1) JP2016071400A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108121711A (en) * 2016-11-28 2018-06-05 北京国双科技有限公司 A kind of data processing method and client device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62151945A (en) * 1985-12-25 1987-07-06 Hitachi Ltd Automatic verification system of repeating test result
JP2008257607A (en) * 2007-04-06 2008-10-23 Fujitsu Ltd Log file storage device and log file management method
JP2010244306A (en) * 2009-04-06 2010-10-28 Nec Corp Device, method and program for gathering of obstacle analysis information
JP2014035595A (en) * 2012-08-07 2014-02-24 Ntt Docomo Inc Testing device for communication system, testing program for communication system, and testing method for communication system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62151945A (en) * 1985-12-25 1987-07-06 Hitachi Ltd Automatic verification system of repeating test result
JP2008257607A (en) * 2007-04-06 2008-10-23 Fujitsu Ltd Log file storage device and log file management method
JP2010244306A (en) * 2009-04-06 2010-10-28 Nec Corp Device, method and program for gathering of obstacle analysis information
JP2014035595A (en) * 2012-08-07 2014-02-24 Ntt Docomo Inc Testing device for communication system, testing program for communication system, and testing method for communication system

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108121711A (en) * 2016-11-28 2018-06-05 北京国双科技有限公司 A kind of data processing method and client device

Similar Documents

Publication Publication Date Title
US10235275B2 (en) Extraction of problem diagnostic knowledge from test cases
US20130191814A1 (en) Test scenario generation method, test scenario generation system, and test scenario generation program
KR102044046B1 (en) Telemetry file hash and conflict detection
JP5208635B2 (en) Information processing apparatus, information processing system, programming support method and program for supporting programming
JP4672532B2 (en) Operator simulation system and operator simulation method
JP4215255B2 (en) Degradation confirmation inspection method, degradation confirmation inspection system, and program therefor
JP2016071400A (en) Test execution device, test execution method, and computer program
US8473943B2 (en) Using ecoprint for cloning of applications
JP2008293382A (en) Automatic test specification generation system
JP5905313B2 (en) Information processing apparatus, information processing method, information processing system, and program
US10698884B2 (en) Dynamic lineage validation system
CN107797917B (en) Performance test script generation method and device
JP2018120256A (en) Setting operation input support apparatus and setting operation input support system
JP2007025820A (en) Risk diagnostic program for software
JP5823478B2 (en) Output file verification system
JP6016623B2 (en) Software execution result deliverable collection apparatus and method
CN113031995A (en) Rule updating method and device, storage medium and electronic equipment
JP6261244B2 (en) WEB application test apparatus and program thereof
JP2020098413A (en) Test support device, test support method and computer program
JP5479389B2 (en) Information processing system, program modification device, program modification method, and program
JP6490935B2 (en) Test execution device, test execution method, and computer program
JP2006260053A (en) Specific subroutine retrieval system and program used therefor
JP6397800B2 (en) Test support system and test support method
CN117149874A (en) Method, device, electronic equipment and storage medium for constructing and maintaining data pipeline
CN116361171A (en) Test processing method and device, electronic equipment and computer storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20170608

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20180511

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180522

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180718

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20181016