Test apparatus, test method, and test program

The test device addresses processing delays in real-time simulation tests by using DTW to adjust judgment points, enhancing test accuracy and automating the inclusion of waveform characteristics in test scenarios.

JP2024123950AActive Publication Date: 2024-09-12HITACHI SOFTWARE ENG
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
JP2023031799
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-03-02
Publication Date
2024-09-12
Estimated Expiration
2043-03-02

AI Technical Summary

Technical Problem

In real-time simulation tests, processing delays due to hardware latency cause deviations from expected judgment points, leading to inaccurate test results, and waveform characteristics cannot be included in automatic test items, requiring manual review and retesting.

Method used

A test device that includes a processor and storage, which executes a test scenario, acquires time-series data, adjusts for processing delays using Dynamic Time Warping (DTW), and determines test pass/fail based on adjusted measurement times and expected values.

Benefits of technology

Improves the accuracy of test pass/fail determination by aligning judgment points with expected values, reducing manual review and retesting, and incorporating waveform characteristics into automatic tests.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2024123950000001
    Figure 2024123950000001
Patent Text Reader

Abstract

To improve the accuracy of determining pass / fail of a test.SOLUTION: A test apparatus is configured to: execute a test for a test target according to a test scenario in which a first expectation value required for operation and instructions to cause the test target to execute the operation and the order of the instructions are defined; acquire, from the test target, first time-series data which are time-series first measurement values regarding the operation associated with the order; identify a correspondence relation between a first measurement time of the first measurement values and a second measurement time of second measurement values, on the basis of the first time-series data and second time-series data in which the time-series second measurement values are defined which are associated with the order of the operation according to the test scenario; adjust the first measurement time on the basis of a time difference between the first measurement time and the second measurement time; and determine whether the test target has passed or failed the test, on the basis of the first measurement values corresponding to the adjusted first measurement time and the first expectation value corresponding to the order in the adjusted first measurement time.SELECTED DRAWING: Figure 7
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present invention relates to a test device, a test method, and a test program for testing a test object. [Background technology]

[0002] Generally, when conducting an automatic test, a test scenario must be created in advance, and the test scenario must describe the operation procedure, as well as the expected values ​​and decision points used for the judgment. The above test scenario is input to the test subject, time-series output waveform data is acquired, the output waveform data is compared with the expected values ​​at the corresponding decision points (time), and the pass / fail result of the test is output.

[0003] Patent Document 1 discloses a misfire detection method for detecting the occurrence of a misfire in an internal combustion engine. This misfire detection method includes a measurement step of measuring the exhaust temperature of the internal combustion engine, a synchronization step of synchronizing a target waveform of the exhaust temperature measured by the measurement step with a predetermined reference waveform so as to increase the mutual correlation, and a determination step of aligning the target waveform after the synchronization with the reference waveform after the synchronization based on a dynamic time warping method, and determining the presence or absence of a misfire based on the difference between the target waveform and the reference waveform after the alignment.

[0004] Patent Document 2 discloses a verification system for verifying the operation of a program executed in a device. In this verification system, a tester can create a test specification representing a verification method in the form of, for example, a sequence diagram in a visually recognizable manner via a UML modeling tool 50 (hereinafter, the tool). Information representing the sequence diagram created by the tester via the tool is converted into a test script that can be recognized and executed by a CAN bus monitor by a script generation function in the tool. The CAN bus monitor monitors the operation of the ECU to be verified, judges whether the actual operation of the ECU matches the test specification represented by the test script, and outputs a test report representing the judgment result to the outside. [Prior art documents] [Patent documents]

[0005] [Patent Document 1] JP 2012-97603 A [Patent Document 2] JP 2010-15240 A Summary of the Invention [Problem to be solved by the invention]

[0006] However, in the case of real-time simulation (especially real-time simulation including hardware), even if the exact same test scenario is executed, the acquired output waveform data will not be completely consistent. This is because of latency, which is a hardware factor, and processing delays caused by the processing accuracy (real-time performance) of executing the scenario. As a result, deviations from the expected decision point occur, resulting in test failures.

[0007] Currently, if a test fails, the test scenario must be reviewed (the decision point must be adjusted) and the automated test must be performed again. Alternatively, it is necessary to explain the reason for the failure and prove that there are no problems with the test.

[0008] In addition, in tests at the above judgment points, the waveform features (shape) cannot be included in the automated test items. Currently, when conducting tests that include the waveform features (shape), the acquired data is visualized and the waveform shape is judged visually.

[0009] An object of the present invention is to improve the accuracy of determining whether a test is passed or failed. [Means for solving the problem]

[0010] A test apparatus according to one aspect of the invention disclosed in the present application includes a processor for executing a program and a storage device for storing the program, the processor performing a test of the test object according to a test scenario that defines an instruction for causing a test object to execute an operation, an order of the instructions, and a first expected value required for the operation; an acquisition process for acquiring, from the test object, first time-series data that is a first time-series measurement value related to the operation associated with the order obtained by the test process; and a storage device for storing the program, the first time-series data acquired by the acquisition process and the test scenario. and performing an adjustment process of adjusting the first measurement time based on a time difference between the first measurement time and the second measurement time, a judgment process of judging whether the test for the test object passes or fails based on the first measurement time adjusted by the adjustment process and the first expected value corresponding to the order of the operations at the first measurement time after the adjustment, and an output process of outputting the judgment result obtained by the judgment process. Effect of the Invention

[0011] According to the representative embodiment of the present invention, it is possible to improve the accuracy of pass / fail judgment of a test. Problems, configurations and effects other than those described above will become apparent from the following description of the examples. [Brief description of the drawings]

[0012] [Figure 1] FIG. 1 is a block diagram showing an example of a hardware configuration of a test device. [Diagram 2] FIG. 2 is a block diagram showing an example of the functional configuration of the test apparatus. [Diagram 3] FIG. 3 is an explanatory diagram illustrating an example of the first automatic test execution determination process. [Figure 4] FIG. 4 is an explanatory diagram showing an example of the first test scenario. [Diagram 5]FIG. 5 is an explanatory diagram illustrating an example of time-series data. [Figure 6] FIG. 6 is an explanatory diagram showing an example of the first test result. [Figure 7] FIG. 7 is a diagram illustrating an example of the second automatic test execution determination process. [Figure 8] FIG. 8 is an explanatory diagram showing an example of the second test scenario. [Figure 9] FIG. 9 is an explanatory diagram illustrating an example of the reference time-series data. [Figure 10] FIG. 10 is an explanatory diagram showing an example of the second test result. [Figure 11] FIG. 11 is a graph showing an example of data mapping by DTW. [Figure 12] FIG. 12 is a flowchart illustrating an example of a reference time-series data generating process performed by the test device. [Figure 13] FIG. 13 is a flowchart illustrating an example of a procedure for a time-series data generation process performed by the test device. [Figure 14] FIG. 14 is a flowchart showing an example of a procedure for executing an automatic decision point adjustment test by the test device. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0013] <Test equipment hardware configuration example> FIG. 1 is a block diagram showing an example of a hardware configuration of a test device. The test device 100 includes a processor 101, a storage device 102, an input device 103, an output device 104, and a communication interface (communication IF) 105. The processor 101, the storage device 102, the input device 103, the output device 104, and the communication IF 105 are connected by a bus 106. The processor 101 controls the test device 100. The storage device 102 serves as a working area for the processor 101. The storage device 102 is a non-transient or temporary recording medium that stores various programs and data. Examples of the storage device 102 include a read only memory (ROM), a random access memory (RAM), a hard disk drive (HDD), and a flash memory. The input device 103 inputs data. Examples of the input device 103 include a keyboard, a mouse, a touch panel, a numeric keypad, a scanner, a microphone, and a sensor. The output device 104 outputs data. The output device 104 may be, for example, a display, a printer, or a speaker. The communication IF 105 connects to a network and transmits and receives data.

[0014] <Example of Functional Configuration of Test Apparatus 100> 2 is a block diagram showing an example of a functional configuration of the test apparatus 100. The test apparatus 100 includes an automatic test execution unit 201, a judgment unit 202, a first communication unit 203, a test scenario 204, time-series data 205, test results 206, and reference time-series data 207. The test apparatus 100 has an automatic judgment point adjustment function that automatically adjusts a judgment point taking into account a delay in the simulation operation of the test target 210, and enables test judgment at an expected judgment point.

[0015] Specifically, the automatic test execution unit 201, the judgment unit 202, and the first communication unit 203 are functions realized by, for example, having the processor 101 execute a program stored in the storage device 102 shown in Fig. 1. The test scenario 204, the time-series data 205, the test result 206, and the reference time-series data 207 are data stored in the storage device 102.

[0016] Moreover, the test object 210 is a device to be tested by the test device 100. The test object 210 may be any device that operates over time. The test object 210 is, for example, a moving object such as an automobile. In this embodiment, a simulation operation test of an automobile will be described as an example. The test object 210 has software 211 that causes the test object 210 to perform a simulation operation, and a second communication unit 212.

[0017] <First automatic test execution decision process> 3 is an explanatory diagram showing an example of a first automatic test execution judgment process. The first automatic test execution judgment process 310 is a process executed by the test device 100, but is a process in the case where the above-mentioned automatic judgment point adjustment function is not applied. Specifically, for example, the test device 100 executes a test scenario execution process 311, a first communication process 312, a time-series data acquisition process 313, and a test judgment process 314 by the first automatic test execution judgment process 310.

[0018] The test scenario execution process 311 is a process in which the automatic test execution unit 201 reads the first test scenario 304 and executes the test target 210 according to the commands written in the first test scenario 304 .

[0019] The first communication process 312 is a process of communicating with the test subject 210 via the first communication unit 203 which is the communication IF 106 .

[0020] The time series data acquisition process 313 is a process for acquiring the time series data 205 received by the first communication process 312 from the test target 210 by the test scenario execution process 311 .

[0021] The test judgment process 314 is a process in which the judgment unit 202 compares the time series data 205 with an expected value at a corresponding judgment point (time) to judge whether the test passes or fails, and outputs the time series data 205 and a first test result 306.

[0022] The test target environment 320 is a test environment in the test target 210 , and uses the software 211 to control the second communication unit 212 , which is a communication IF, to execute a second communication process 321 with the first communication unit 203 .

[0023] <First Test Scenario 304> 4 is an explanatory diagram showing an example of the first test scenario 304. The first test scenario 304 is a test scenario that does not support the automatic decision point adjustment function. The first test scenario 304 is data that specifies the commands and the order of the commands that cause the test target 210 to perform an operation, and the expected values ​​required for the operation.

[0024] The first test scenario 304 has, as fields, a sequence number 401, an instruction 402, a set value 403, and an expected value 404.

[0025] The sequence No. 401 is an ascending number indicating the order of operations to be performed by the test subject 210, and the instructions 402 are executed in ascending order. The value # (# is an integer of 1 or more) of the sequence No. 401 may be written as "sequence (#)". Note that "s" is an abbreviation for seconds (sec) (this is the same for other figures).

[0026] The instruction 402 is a command to cause the test target 210 to perform an operation. The set value 403 is a value set in the test target 210 in the instruction 402. The expected value 404 is a value expected when the instruction 402 is given in the set value 403. In this example, the expected value 404 indicates the presence or absence of a failure by the instruction (Fail_Injection) that causes a failure, which is the instruction 402 in the sequence (5), using Fail_flag. "0" indicates that no failure has occurred, and "1" indicates that a failure has occurred.

[0027] The first test scenario 304 will be explained in the order of sequence No. 401.

[0028] Sequence (1) The test apparatus 100 turns on the IGN (ignition) of the test subject 210.

[0029] Sequence (2) Wait 5 seconds.

[0030] Sequence (3) Increases accelerator pedal pressure by 40%.

[0031] Sequence (4) Wait 5 seconds.

[0032] Sequence (5) A command that causes a failure (Fail_Injection) is turned ON to cause a failure in the test subject 210 .

[0033] Sequence (6)~(8) JudgePoint is a function by which the test apparatus 100 judges whether or not a failure has occurred in the test target 210 due to an instruction (Fail_Injection) that causes a failure after the cumulative time described in the setting value 403 has elapsed.

[0034] In sequence (6), the expected value 404 is set to "0" 0.1 seconds after the command (Fail_Injection) that causes a failure is turned ON. In sequence (7), the expected value 404 is set to "1" 0.2 seconds after the command (Fail_Injection) that causes a failure is turned ON. In sequence (8), the expected value 404 is set to "0" 0.3 seconds after the command (Fail_Injection) that causes a failure is turned ON.

[0035] In this way, the first test scenario 304 is a test scenario for verifying that Fail_flag becomes “1” within 0.1 seconds after 0.2 seconds have passed since the instruction (Fail_Injection) that causes a failure, which is instruction 402 in sequence (5), turns ON (set value 403).

[0036] <Time Series Data 205> 5 is an explanatory diagram showing an example of the time series data 205. The time series data 205 is a time series of measured values ​​related to the operation of the test target 210 according to the instruction 402 and the set value 403 associated with the sequence (#). The time series data 205 is a log obtained as a result of inputting the first test scenario 304 to the test target 210. The time series data 205 has a simulation time 501, a sequence No. 401, and a judgment value 502 as fields.

[0037] A simulation time 501 is the actual time that has elapsed since the start of the test. A decision value 502 is a measurement value that indicates whether or not a failure (Fail_flag) has occurred due to an instruction that causes a failure (Fail_Injection).

[0038] The time series data 205 indicates that the instruction (Fail_Injection) that causes a failure, which is the instruction 402 of the sequence (5), turned ON (setting value 403) during the 0.3 second period from 10.5 (s) to 10.7 (s) of the simulation time 501 (symbol 510).

[0039] Furthermore, the time series data 205 indicates the period from when the simulation time 501 is 10.5 (s) until the judgment value 502 becomes "1" (reference numeral 520).

[0040] That is, the time series data 205 indicates that it took 0.3 (s) to process the instruction (Fail_Injection) that causes a failure, which is the instruction 402 of the sequence (5), due to a processing delay occurring in the sequence (5) of the test target 210. Therefore, the time series data 205 is different from the expected value 404.

[0041] <First Test Result 306> 6 is an explanatory diagram showing an example of the first test result 306. The first test result 306 has, as fields, a sequence number 401, an instruction 402, a setting value 403, and a first judgment result 600. The first judgment result 600 indicates a result of comparing the expected value 404 with the judgment value 502.

[0042] "-" indicates that the instruction 402 is not a "JudgePoint" and therefore a comparison between the expected value 404 and the judgment value 502 has not been performed.

[0043] "OK" indicates that the judgment value 502 matches the expected value 404. "NG x(y)" indicates that the judgment value 502 does not match the expected value 404. "x" indicates the judgment value 502, and "(y)" indicates the expected value 404.

[0044] That is, in sequence (7), the judgment value 502 is "0" and the expected value 404 is "1," which indicates a mismatch, and in sequence (8), the judgment value 502 is "1" and the expected value 404 is "0," which indicates a mismatch. Therefore, the test result is a fail.

[0045] <Second automatic test execution decision process> 7 is an explanatory diagram showing an example of the second automatic test execution judgment process. The second automatic test execution judgment process 710 is a process executed by the test device 100, and is a process when the above-mentioned automatic judgment point adjustment function is applied. Specifically, for example, the test device 100 executes the test scenario execution process 311, the first communication process 312, the time-series data acquisition process 313, the automatic judgment point adjustment process 711, and the test judgment process 314 by the second automatic test execution judgment process 710.

[0046] The test scenario execution process 311 is a process in which the automatic test execution unit 201 reads the second test scenario 704 and executes the test target 210 according to the commands written in the second test scenario 704 .

[0047] The automatic decision point adjustment process 711 is a process in which the decision unit 202 automatically adjusts the decision point (time) in the time series data 205 by using the reference time series data 207 .

[0048] The test judgment process 314 is a process in which the judgment unit 202 compares the time series data 205 with an expected value at the corresponding judgment point (time) based on the adjustment result by the automatic judgment point adjustment process 711, judges whether the test passes or fails, and outputs the time series data 205 and a second test result 706.

[0049] <Second Test Scenario 704> 8 is an explanatory diagram showing an example of the second test scenario 704. The second test scenario 704 is a test scenario corresponding to the automatic decision point adjustment function. The second test scenario 704 has, as fields, a sequence number 401, an instruction 402, a set value 403, an expected value 404, and a DTW expected value 805. The values ​​of the sequence number 401, the instruction 402, the set value 403, and the expected value 404 in the second test scenario 704 are the same as those in the first test scenario 304.

[0050] The DTW expected value 805 is an expected value supplied to a waveform indicating the change over time of the Fail_flag according to the sequence No. 401 when the instruction 402 is given in the setting value 403. DTW is an abbreviation for Dynamic Time Warping.

[0051] In this example, since the DTW expected value 805 is "0", it is required that the waveform showing the change over time of Fail_flag in the reference time-series data 207 matches the waveform showing the change over time of Fail_flag in the second test scenario 704. The DTW expected value 805 is set in the range of 0 to 1.

[0052] <Reference Time Series Data 207> 9 is an explanatory diagram showing an example of the reference time series data 207. The reference time series data 207 is, for example, time series data obtained as a result of simulating the test subject 210 in advance using the same test scenario as the second test scenario 704. It may also be time series data when a test result that was previously determined to be a pass was obtained.

[0053] The reference time series data 207 has, as fields, a simulation time 501, a sequence number 401, and a reference judgment value 902.

[0054] The reference judgment value 902 is a measurement value indicating the presence or absence of a failure (Fail_flag) caused by an instruction (Fail_Injection) that causes a failure when the reference time-series data 207 is generated.

[0055] No processing delay occurs in sequence (5) in the reference time-series data 207. For this reason, the reference determination value 902 becomes “1” (reference number 920) at 10.7 (s), which is 0.2 seconds after 10.5 (s) (reference number 910), which is the simulation time 501 when sequence (5) is executed.

[0056] <Second Test Result 706> 10 is an explanatory diagram showing an example of the second test result 706. The second test result 706 has, as fields, a sequence number 401, an instruction 402, a setting value 403, a second judgment result 1000, and a DTW judgment result 1001. The second judgment result 1000 shows the result of comparing the expected value 404 with the judgment value 502 adjusted by the automatic judgment point adjustment process 711.

[0057] “OK(zs)” indicates that the judgement value 502 adjusted by the automatic judgement point adjustment process 711 matches the expected value 404. “z” is the adjustment time (s) at the JudgePoint corrected by DTW based on the time series data 205.

[0058] 5, judgment values ​​502 (0,0,1) (reference numeral 520) at 10.6 (s), 10.7 (s), and 10.8 (s) of simulation time 501 are compared with expected value 404, but due to the DTW correction, judgment values ​​502 (0,1,0) (reference numeral 530) at 10.7 (s), 10.8 (s), and 10.9 (s) of simulation time 501 are compared with expected value 404. In this example, in sequences (6) to (8), the judgment timing of JudgePoint is increased by 0.1 (s) due to the DTW correction, so "z" (=+0.1) is added to the second judgment result 1000 as the adjustment time (s).

[0059] In the first test result 306 in FIG. 6, the first judgment result 600 of the JudgePoints of sequences (7) and (8) is "NG", but in the second test result 706, it becomes "OK".

[0060] The DTW judgment result 1001 is an index value indicating whether the DTW value matches the DTW expected value 805 of the second test scenario 704. For example, since the DTW expected value 805 is "0", if the DTW value is "0", the DTW judgment result 1001 is "OK", and if the DTW value is a value greater than "0", the DTW judgment result 1001 is "NG".

[0061] The DTW expected value 805 is not limited to "0" and may be in a range such as 0.0≦DTW expected value 805<threshold value th. Since the DTW value is 0.0 or more, the threshold value th can be set to any value equal to or greater than 0.0. However, even if the DTW value is close to 0.0, it is preferable to set the threshold value th to a value of 0.5 or less in order to make the DTW judgment result 1001 "OK".

[0062] Here, the calculation of the DTW value will be explained. Let two time series data be x and y. The value x of the time series data x and y at time t (1≦t≦T) is t ,y t The waveform is expressed as follows. Time series data x at time t=w x and time series data y at time t=wy By aligning, we can say that w = (w x ,w y ), and the entire waveform alignment is divided into a set of K correspondences into a warping path W = {w1, w2, …, w K} where w k =(w k x ,w k y ) (k is an integer satisfying 1≦k≦K), the DTW value is defined by the following equation (1).

[0063]

number

[0064] The DTW value indicates the similarity between the time series data x and y. The DTW value ranges from 0 to 1, similar to the DTW expected value 805. The DTW value is calculated by dividing the two time series data x and y into the Fail_flag (reference judgment value 902) in the reference time series data 207 and the Fail_flag (judgment value 502) in the second test scenario 704.

[0065] The smaller the DTW expected value 805, the more similar the waveform indicating the change over time of Fail_flag (reference judgment value 902) in the reference time-series data 207 and the waveform indicating the change over time of Fail_flag (judgment value 502) in the second test scenario 704 become.

[0066] <DTWによるデータマッピング> 11 is a graph showing an example of data mapping by DTW. Graph 1100 has a horizontal axis 1110, a first vertical axis 1121, and a second vertical axis 1122. The horizontal axis 1110 is the simulation time 501. The first vertical axis 1121 is the reference judgment value 902 of the reference time series data 207. The second vertical axis 1122 is the judgment value 502 of the time series data 205. (#)tt.ts near the circle indicates the value tt.t of the simulation time 501 of sequence (#). For example, (5)10.6s indicates the value 10.6s of the simulation time 501 of sequence (5).

[0067] In order to avoid overlapping of the first waveform W1 and the second waveform W2, the second waveform W2 is displayed shifted in the direction of the first vertical axis 1121 for the sake of convenience.

[0068] The first waveform W1 shows the change over time of the reference judgment value 902 in the reference time series data 207. The first waveform W1 is the waveform before adjustment. The second waveform W2 shows the change over time of the judgment value 502 in the time series data 205. The second waveform W2 is the waveform after adjustment. In the first waveform W1 and the second waveform W2, points surrounded by the same circle are mapped to each other.

[0069] Specifically, by executing DTW, for example, the correspondence between sequence (6) 10.6 s in which the value in the first waveform W1 is “0” and sequence (5) 10.7 s in which the value in the second waveform W2 is “0” and the time difference between them, +1.0 s (= 10.7 s − 10.6 s), are identified.

[0070] In addition, the correspondence between the sequence (7) 10.7 s in which the value in the first waveform W1 is "1" and the sequence (6) 10.8 s in which the value in the second waveform W2 is "1" and the time difference therebetween, +1.0 s (=10.8 s-10.7 s), are identified.

[0071] In addition, the correspondence between the sequence (8) 10.8 s in which the value in the first waveform W1 is "0" and the sequence (7) 10.9 s in which the value in the second waveform W2 is "0" and the time difference therebetween of +1.0 s (=10.8 s-10.7 s) are identified.

[0072] Furthermore, when the DTW value is calculated using the above formula (1) within the interval of 9 s to 12 s in the simulation time 501 indicated by the horizontal axis 1110, the DTW value becomes DTW=0.

[0073] By applying the DTW in this manner, the test apparatus 100 can obtain the correspondence between points in the first waveform W1 and the second waveform W2 and the DTW value related to the first waveform W1 and the second waveform W2.

[0074] <Reference time series data generation process> Fig. 12 is a flowchart showing an example of a reference time series data generation process procedure by the test device 100. Fig. 12 shows a process in the second automatic test execution determination process in which the test device 100 generates reference time series data 207 by simulation through a test scenario execution process 311, a first communication process 312, and a time series data acquisition process 313. Before the simulation is executed, the entry of the reference time series data 207 is empty.

[0075] The test apparatus 100 reads the second test scenario 704, and analyzes (converts into a script file) the sequence number 401, the instruction 402, and the setting value 403 (step S1201).

[0076] The test apparatus 100 starts measuring a measurement signal used in the judgment of an automatic test, in this example, a reference judgment value 902 (Fail_flag) (step S1202).

[0077] The test apparatus 100 judges whether execution of all sequences of sequence No. 401 has been completed (step S1203). If execution of all sequences of sequence No. 401 has not been completed (step S1203: No), the test apparatus 100 judges whether the current simulation time 501 (current simulation time) is equal to or longer than the sequence No. execution time (step S1204).

[0078] The current simulation time is "0.0 s" at the start of step S1202, and is increased by one step (0.1 s) by the simulation in step S1207.

[0079] The sequence number execution time is the accumulated time up to the execution of the sequence of sequence number 401 (hereinafter, current sequence (#)) up to now. Since the sequences (#) are executed in ascending order of sequence number 401, the current sequence (#) is the sequence number 401 that has not been executed and is the youngest. The sequence number execution time is "0.0 s" at the start of step S1202, and is accumulated in step S1206 as sequence (#) is executed.

[0080] If the current simulation time is equal to or greater than the sequence No. execution time (step S1204: Yes), the process proceeds to step S1205. On the other hand, if the current simulation time is not equal to or greater than the sequence No. execution time (step S1204: No), the process proceeds to step S1207.

[0081] At the start of step S1202, the current simulation time and the sequence No. execution time are both "0.0 s", so the process moves to step S1204.

[0082] The test apparatus 100 executes the instruction 402 of the current sequence (#) (step S1205). At the start of step S1202, the current sequence (#) is sequence (1). Therefore, the test apparatus 100 executes a process of changing the instruction 402 of sequence (1) from "IGN" to the setting value 403 of "ON." As a result, the reference judgment value 902 is output as the value of the measurement signal.

[0083] In sequence (1), the instruction 402 is not an instruction (Fail_Injection) that causes a failure, so no failure is simulated. Therefore, the value of the reference judgment value 902 (Fail_flag) that indicates the presence or absence of a failure is "0".

[0084] The test apparatus 100 updates the current sequence number execution time (step S1206). Specifically, for example, the test apparatus 100 updates the sequence number execution time by adding the time required to execute the instruction 402 of the current sequence (#) in step S1204 to the sequence number execution time.

[0085] For example, if sequence (1) took 0.1 seconds, the sequence number execution time would be updated from "0.0 seconds" to "0.1 seconds."

[0086] Next, the test apparatus 100 advances the current simulation time by one step (step S1207). Specifically, for example, the test apparatus 100 adds 0.1 s to the current simulation time. As a result, the current simulation time is updated from "0.0 s" to "0.1 s".

[0087] Next, the test apparatus 100 writes the current simulation time, the current sequence (#), and the value of the measurement signal resulting from the execution of step S1205 to the reference time-series data 207 (step S1208). If the current simulation time is "0.1 s", the current simulation time "0.1 s", the sequence No. 401 of the current sequence (1) which is "1", and the value of the measurement signal resulting from the execution of the current sequence (1) which is "0" are written as entries to the reference time-series data 207. Then, the process returns to step S1203.

[0088] Since the sequence number 401 of the current sequence (#) is "1", execution of all sequences has not been completed (step S1203: No), and therefore the process proceeds to step S1204.

[0089] In step S1204, the current simulation time is "0.1 s" and the sequence No. execution time is also "0.1 s", so that step S1204 is satisfied (step S1204: Yes), and the process proceeds to step S1205.

[0090] In step S1205, the test apparatus 100 executes sequence (2). In this case, the test apparatus 100 executes a process of setting the "Wait" instruction 402 of sequence (2) to "5 s" which is the set value 403. As a result, the reference judgment value 902 is output as the value of the measurement signal.

[0091] In sequence (2), the instruction 402 is not an instruction (Fail_Injection) that causes a failure, so no failure is simulated. Therefore, the value of the reference judgment value 902 (Fail_flag) that indicates whether a failure has occurred is "0."

[0092] The test apparatus 100 updates the current sequence No. execution time (step S1206). Because "Wait", which is instruction 402 of sequence (2), is a waiting process, the time required to execute "Wait" becomes the value "5 s" of the set value 403. Therefore, the test apparatus 100 updates the sequence No. execution time to "5.1 s" by adding "5 s", the time required to execute instruction 402 of the current sequence (2) in step S1204, to "0.1 s", which is the sequence No. execution time.

[0093] Next, the test apparatus 100 adds 0.1 s to the current simulation time of "0.1 s" (step S1207), thereby updating the current simulation time from "0.1 s" to "0.2 s".

[0094] Next, the test apparatus 100 writes the current simulation time "0.2 s", the sequence No. 401 of the current sequence (2) which is "2", and the value of the measurement signal which is the execution result of step S1205 which is "0" as an entry in the reference time-series data 207 (step S1208), and then returns to step S1203.

[0095] Since the sequence number 401 of the current sequence (#) is "2", execution of all sequences has not been completed (step S1203: No), and therefore the process proceeds to step S1204.

[0096] In step S1204, the current simulation time is "0.2 s" and the sequence No. execution time is "5.1 s", so step S1204 is not satisfied (step S1204: No), and the process proceeds to step S1207.

[0097] In step S1207, the test apparatus 100 adds 0.1 s to the current simulation time of "0.2 s" (step S1207), thereby updating the current simulation time from "0.2 s" to "0.3 s".

[0098] The test apparatus 100 continues the loop of steps S1204: No, S1207, S1208, and S1203: No until the current simulation time reaches or exceeds "5.1 seconds", which is the sequence No. execution time, as determined by step S1207.

[0099] Thereafter, if the current simulation time becomes equal to or greater than the sequence No. execution time "5.1 s" (step S1204: Yes), the test apparatus 100 executes steps S1205 to S1208, and returns to step S1203.

[0100] Finally, when the test apparatus 100 determines that the execution of all sequences has been completed (step S1203: Yes), it ends the reference time series data generation process, thereby generating the reference time series data 207 as shown in FIG.

[0101] <Time series data generation process> Fig. 13 is a flowchart showing an example of a time-series data generation process procedure by the test device 100. Fig. 13 shows processes in the second automatic test execution determination process in which the test device 100 generates time-series data 205 in a real-time simulation using the test target 210 through a test scenario execution process 311, a first communication process 312, and a time-series data acquisition process 313. The entries of the time-series data 205 before the execution of the real-time simulation using the test target 210 are empty.

[0102] The test apparatus 100 reads the second test scenario 704, and analyzes (converts into a script file) the sequence number 401, the instruction 402, and the setting value 403 (step S1301).

[0103] The test apparatus 100 starts measuring a measurement signal used in automatic test judgment, in this example, the reference judgment value 902 (Fail_flag) (step S1302). With step S1302, the passage of real-time simulation time 501 starts.

[0104] The test apparatus 100 transmits a measurement start signal in step S1302 to the test subject 210 (C1).

[0105] The test apparatus 100 judges whether execution of all sequences of sequence No. 401 has been completed (step S1303). If execution of all sequences of sequence No. 401 has not been completed (step S1303: No), the test apparatus 100 judges whether the current simulation time 501 (current simulation time) is equal to or longer than the sequence No. execution time (step S1204).

[0106] Unlike FIG. 12, the current simulation time is the actual time that has elapsed since the start of measurement in step S1302. It is "0.0 s" at the start of step S1302, and increases as time actually elapses. The sequence number execution time and sequence (#) are the same as in FIG. 12. The sequence number execution time is "0.0 s" at the start of step S1302, and is accumulated in step S1306 by the execution of sequence (#).

[0107] If the current simulation time is equal to or greater than the sequence No. execution time (step S1304: Yes), the process proceeds to step S1305. On the other hand, if the current simulation time is not equal to or greater than the sequence No. execution time (step S1304: No), the process proceeds to step S1303.

[0108] At the start of step S1302, the current simulation time and the sequence No. execution time are both "0.0 s", so the process proceeds to step S1305.

[0109] The test apparatus 100 executes the instruction 402 of the current sequence (#) (step S1305). At the start of step S1302, the current sequence (#) is sequence (1). Therefore, the test apparatus 100 executes a process on the test object 210 to change the instruction 402 of sequence (1), "IGN", to the setting value 403, "ON". In other words, the test apparatus 100 transmits a command to the test object 210 to change "IGN" to "ON" (C2).

[0110] After the test object 210 receives a measurement start signal (C1) from the test equipment 100 through the second communication process 321, each time the test object 210 receives a command (C2) from the test equipment 100, the software 211 executes an operation based on the command (C2) and sequentially reads out the values ​​of the measurement signals generated by the operation (step S1310).

[0111] In sequence (1), the instruction 402 is not an instruction (Fail_Injection) that causes a failure, so no pseudo failure occurs. Therefore, the value of the judgment value 502 (Fail_flag) indicating the presence or absence of a failure is "0." The test object 210 transmits the value of the read measurement signal as the judgment value 502 to the test apparatus 100 by the second communication processing 321 (C3).

[0112] Next, the test apparatus 100 writes the measurement results (current simulation time, current sequence (#), and the value of the measurement signal resulting from the execution of step S1310) as entries in the time series data 205 (step S1306). Assume that the current simulation time becomes "0.1 s" over time. In this case, the test apparatus 100 writes the current simulation time "0.1 s," the sequence No. 401 of the current sequence (1) which is "1," and the value of the measurement signal resulting from the execution of the current sequence (1) which is "0," as entries in the time series data 205.

[0113] The test apparatus 100 updates the current sequence number execution time (step S1306). Specifically, for example, the test apparatus 100 updates the sequence number execution time by taking the time from when the test apparatus 100 transmits a command (C2) to when it receives the value of the measurement signal (C3) as the time required to execute the instruction 402 of the current sequence (#) and adding it to the sequence number execution time.

[0114] For example, if sequence (1) took 0.1 seconds, the sequence number execution time would be updated from "0.0 seconds" to "0.1 seconds."

[0115] Since the sequence number 401 of the current sequence (#) is "1", execution of all sequences has not been completed (step S1303: No), and therefore the process proceeds to step S1304.

[0116] In step S1304, the current simulation time is "0.1 s" and the sequence No. execution time is also "0.1 s", so that step S1304 is satisfied (step S1304: Yes), and the process proceeds to step S1305.

[0117] In step S1305, the test apparatus 100 executes sequence (2). In this case, the test apparatus 100 transmits to the test subject 210 a command to set the "Wait" instruction 402 of sequence (2) to the set value 403 of "5s" (C2).

[0118] In sequence (2), the instruction 402 is not a command (Fail_Injection) that causes a failure, so no pseudo-failure occurs. Therefore, the value of the judgment value 502 (Fail_flag) indicating whether a failure has occurred is "0." The test object 210 transmits the value of the read measurement signal to the test apparatus 100 as the judgment value 502 (C3).

[0119] In addition, the test object 210 continues to wait until the set value 403 of "5 seconds" has elapsed due to the "Wait" instruction 402 in sequence (2). During that time, the test object 210 continues to transmit the value "0" of the read measurement signal to the test apparatus 100 as the judgment value 502 (C3).

[0120] The measurement results (current simulation time, current sequence (#), and the value of the measurement signal resulting from the execution of step S1310) are written as entries into the time-series data 205 (step S1306). Assume that the current simulation time becomes "0.2 s" as time passes. In this case, the test apparatus 100 writes the current simulation time "0.2 s," the sequence No. 401 of the current sequence (1) which is "2," and the value of the measurement signal resulting from the execution of the current sequence (2) which is "0" into the time-series data 205 as entries.

[0121] The test apparatus 100 updates the current sequence No. execution time (step S1307). Since the "Wait" instruction 402 of sequence (2) is a process that causes the test target 210 to wait, the time required to execute "Wait" becomes the value "5 s" of the set value 403. Therefore, the test apparatus 100 updates the sequence No. execution time to "5.1 s" by adding the value "5 s" of the set value 403 to the sequence No. execution time of "0.2 s". Then, the process returns to step S1303.

[0122] Since the sequence number 401 of the current sequence (#) is "2", execution of all sequences has not been completed (step S1303: No), and therefore the process proceeds to step S1304.

[0123] In step S1304, the current simulation time is "0.2 s" and the sequence No. execution time is "5.1 s", so step S1304 is not satisfied (step S1304: No), and the process proceeds to step S1303.

[0124] The test apparatus 100 continues the loop of steps S1304: No and S1303: No until the current simulation time becomes equal to or greater than the sequence No. execution time "5.1 s".

[0125] Thereafter, if the current simulation time becomes equal to or greater than the sequence No. execution time "5.1 s" as time passes (step S1304: Yes), the test apparatus 100 executes steps S1305 to S1307, and returns to step S1303.

[0126] Finally, when the test apparatus 100 determines that the execution of all sequences has been completed (step S1303: Yes), it ends the time-series data generation process, thereby generating the time-series data 205 as shown in FIG.

[0127] <Automatic judgment point adjustment test execution process> Fig. 14 is a flowchart showing an example of an automatic decision point adjustment test execution process procedure by the test apparatus 100. Fig. 14 shows a process in which the test apparatus 100 executes an automatic decision point adjustment test by using the reference time series data 207 and the time series data 205 acquired in Fig. 13 through the automatic decision point adjustment process 711 and the test judgment process 314 in the second automatic test execution judgment process. Note that Fig. 14 shows an example of executing an automatic decision point adjustment test for one type of measurement signal, but if there are multiple types of measurement signals in one second test scenario 704, the automatic decision point adjustment test is executed for the number of types of measurement signals.

[0128] The test apparatus 100 reads the reference time series data 207 and the time series data 205 acquired in FIG. 13 (step S1401).

[0129] The test apparatus 100 acquires time-series values ​​of the Judge Point to be adjusted from each of the reference time-series data and the time-series data (step S1402). Specifically, for example, the test apparatus 100 acquires the reference judgment value 902 when the simulation time 501 of the reference time-series data 207 is from 0.1 s to 12.0 s, and the judgment value 502 when the simulation time 501 of the time-series data 205 is from 0.1 s to 12.0 s.

[0130] The test apparatus 100 uses the DTW algorithm to identify the adjustment destination time and the adjustment time from the adjustment source for each Judge Point, and calculates the DTW value (step S1403). The DTW algorithm associates the adjustment source time with the adjustment destination time.

[0131] As described above, the adjustment source is the reference judgment value 902 of the time-series Judge Point in the reference time-series data 207. The adjustment source time is the simulation time 501 at the reference judgment value 902. In the example of Fig. 11, the sequence (6) 10.6 s, sequence (7) 10.7 s, and sequence (8) 10.8 s of the first waveform W1 are the adjustment source times.

[0132] As described above, the adjustment destination is the judgment value 502 of the time-series Judge Point in the time-series data 205, and the adjustment destination time is the simulation time 501 at the judgment value 502. In the example of Fig. 11, the adjustment destination times are sequence (5) 10.7 s, sequence (6) 10.8 s, and sequence (7) 10.9 s of the second waveform W2.

[0133] The adjustment time from the adjustment source is the time difference obtained by subtracting the associated adjustment source time from the adjustment destination time.

[0134] The test apparatus 100 compares the expected value 404 of the second test scenario 704 with the judgment value 502 of the time-series data 205 at the time-adjusted Judge Point to generate a second judgment result 1000 (step S1404).

[0135] The time-adjusted Judge Points are sequences (5)-(7) in the adjusted time series data 205, which correspond to sequences (6)-(8) in the reference time series data 207, which is the source of the adjustment. The judgment value 502 of the sequences (5)-(7) is (0,1,0). The expected value 404 of the sequences (6)-(8) in the second test scenario 704 is (0,1,0).

[0136] Therefore, the judgment value 502 of sequence (5) in the time series data 205 after time adjustment from sequence (6) in the reference time series data 207 is “0”, and the expected value 404 of sequence (6) in the second test scenario 704 is “0”, so the two match.

[0137] The adjustment time from sequence (6) in the reference time series data 207, which is the adjustment source, to sequence (5) in the time series data 205, which is the adjustment destination, is +1.0 s. Therefore, the value of the second judgment result 1000 for sequence (6) in the second test scenario 704 is “OK+1.0 s”.

[0138] In addition, the judgment value 502 of sequence (6) in the time series data 205 after time adjustment from sequence (7) in the reference time series data 207 is “1”, and the expected value 404 of sequence (7) in the second test scenario 704 is “1”, so the two match.

[0139] The adjustment time from sequence (7) in the reference time series data 207, which is the adjustment source, to sequence (6) in the time series data 205, which is the adjustment destination, is +1.0 s. Therefore, the value of the second judgment result 1000 for sequence (7) in the second test scenario 704 is “OK+1.0 s”.

[0140] In addition, the judgment value 502 of sequence (7) in the time series data 205 after time adjustment from sequence (8) in the reference time series data 207 is “0”, and the expected value 404 of sequence (8) in the second test scenario 704 is “0”, so the two match.

[0141] The adjustment time from sequence (8) in the reference time series data 207, which is the adjustment source, to sequence (7) in the time series data 205, which is the adjustment destination, is +1.0 s. Therefore, the value of the second judgment result 1000 for sequence (8) in the second test scenario 704 is “OK+1.0 s”.

[0142] The test apparatus 100 compares the DTW expected value 805 with the DTW value to generate a DTW decision result 1001 (step S1405). As shown in Fig. 8, the DTW expected value 805 is "0". Furthermore, since the first waveform W1 and the second waveform W2 match due to the DTW, the DTW value = "0". Therefore, since the DTW expected value 805 and the DTW value match, the DTW decision result 1001 is "OK".

[0143] The test apparatus 100 outputs the second test result 706 as shown in FIG. 10 (step S1406).

[0144] In this way, according to this embodiment, the test device 100 automatically adjusts the decision point taking into account the processing delay, and performs the test decision at the expected decision point. Specifically, the test device 100 automatically adjusts the decision point by using the DTW algorithm that measures the similarity between time-series data, and uses the calculated DTW value for the test decision. Therefore, the test accuracy can be improved.

[0145] Specifically, even if latency, which is a hardware factor of the test target 210, and a processing delay occurs when executing a test scenario, the waveform characteristics of the time-series data are also included in the automatic test items, so that it is possible to suppress erroneous judgments (failures) in the test results due to deviations in the judgment points. In addition, by suppressing erroneous judgments (failures) in the test results, it is possible to suppress wasteful work such as reviewing the test scenario, investigating the cause of the failure, and conducting a retest, which arise due to erroneous judgments (failures) in the test results. Therefore, it is possible to shorten the test period.

[0146] In particular, in the V-process of vehicle development, by utilizing the second test scenario 704 used in the test performed in the highly abstract simulation environment (PC simulator) in the previous stage and the reference time-series data 207, which is the output result of the test, in the subsequent stages, it is possible to realize a seamless automatic test configuration for the entire process.

[0147] The present invention is not limited to the above-described embodiments, and includes various modified examples and equivalent configurations within the spirit of the appended claims. For example, the above-described embodiments have been described in detail to clearly explain the present invention, and the present invention is not necessarily limited to those having all of the configurations described. Also, a part of the configuration of one embodiment may be replaced with a configuration of another embodiment. Also, a configuration of another embodiment may be added to a configuration of one embodiment. Also, a part of the configuration of each embodiment may be added, deleted, or replaced with another configuration.

[0148] Furthermore, each of the aforementioned configurations, functions, processing units, processing means, etc. may be realized in hardware, for example by designing some or all of them as an integrated circuit, or may be realized in software by a processor interpreting and executing a program that realizes each function.

[0149] Information such as programs, tables, files, etc. that realize each function can be stored in a storage device such as a memory, a hard disk, or an SSD (Solid State Drive), or in a recording medium such as an IC (Integrated Circuit) card, an SD card, or a DVD (Digital Versatile Disc).

[0150] In addition, the control lines and information lines shown are those considered necessary for the explanation, and do not necessarily show all the control lines and information lines necessary for implementation. In reality, it can be considered that almost all components are connected to each other. [Explanation of symbols]

[0151] 100 Test Equipment 101 Processor 102 Storage Devices 201 Automatic Test Execution Unit 202 Judgment section 203 First Communications Department 204 Test Scenarios 205 Time Series Data 206 Test Results 207 Reference Time Series Data 210 Test Subjects 211 Software 212 2nd Communications Department 304 First Test Scenario 306 1st Test Results 310 First automatic test execution decision process 311 Test scenario execution process 312 First communication process 313 Time series data acquisition processing 314 Examination Judgment Processing 320 Test environment 321 Second communication processing 704 Second Test Scenario 706 2nd Test Results

Claims

1. A test apparatus having a processor that executes a program and a storage device that stores the program, The processor, a test process for executing a test of the test object according to a test scenario in which an instruction for causing the test object to execute an operation, an order of the instructions, and a first expected value required for the operation are defined; an acquisition process of acquiring, from the test subject, first time-series data which is a first time-series measurement value relating to the motion associated with the order obtained by the test process; an adjustment process for determining a correspondence relationship between a first measurement time of the first measurement value and a second measurement time of the second measurement value based on first time-series data acquired by the acquisition process and second time-series data in which a time-series second measurement value associated with the order of the operations according to the test scenario is defined, and adjusting the first measurement time based on a time difference between the first measurement time and the second measurement time; a determination process for determining whether the test for the test object passes or fails based on the first measured value corresponding to the first measurement time after adjustment by the adjustment process and the first expected value corresponding to the order at the first measurement time after the adjustment; an output process for outputting a determination result obtained by the determination process; A test apparatus comprising:

2. 2. The test device according to claim 1, the determination result includes a first comparison result between the first measurement value corresponding to the adjusted first measurement time and the first expected value corresponding to the sequence of the operations at the adjusted first measurement time, and the time difference. A test device comprising:

3. 2. The test device according to claim 1, a second expected value required for the arrangement of the first expected values ​​according to the order is defined in the test scenario; In the adjustment process, the processor calculates a similarity between the first time series data and the second time series data; In the determination process, the processor determines whether the test has passed or failed based on the similarity calculated by the adjustment process and the second expected value. A test device comprising:

4. 4. The test device according to claim 3, the determination result includes a second comparison result between the similarity and the second expected value. A test device comprising:

5. 2. The test device according to claim 1, In the adjustment process, the processor identifies the correspondence relationship based on a dynamic time warping method. A test device comprising:

6. 4. The test device according to claim 3, In the adjustment process, the processor calculates the similarity based on a dynamic time warping method. A test device comprising:

7. A test method using a test apparatus having a processor that executes a program and a storage device that stores the program, comprising: The processor, a test process for executing a test of the test object according to a test scenario in which an instruction for causing the test object to execute an operation, an order of the instructions, and a first expected value required for the operation are defined; an acquisition process of acquiring, from the test subject, first time-series data which is a first time-series measurement value relating to the motion associated with the order obtained by the test process; an adjustment process for determining a correspondence relationship between a first measurement time of the first measurement value and a second measurement time of the second measurement value based on first time-series data acquired by the acquisition process and second time-series data in which a time-series second measurement value associated with the order of the operations according to the test scenario is defined, and adjusting the first measurement time based on a time difference between the first measurement time and the second measurement time; a determination process for determining whether the test for the test object passes or fails based on the first measured value corresponding to the first measurement time after adjustment by the adjustment process and the first expected value corresponding to the order at the first measurement time after the adjustment; an output process for outputting a determination result obtained by the determination process; A test method comprising:

8. The processor: a test process for executing a test of the test object according to a test scenario in which an instruction for causing the test object to execute an operation, an order of the instructions, and a first expected value required for the operation are defined; an acquisition process of acquiring, from the test subject, first time-series data which is a first time-series measurement value relating to the motion associated with the order obtained by the test process; an adjustment process for determining a correspondence relationship between a first measurement time of the first measurement value and a second measurement time of the second measurement value based on first time-series data acquired by the acquisition process and second time-series data in which a time-series second measurement value associated with the order of the operations according to the test scenario is defined, and adjusting the first measurement time based on a time difference between the first measurement time and the second measurement time; a determination process for determining whether the test for the test object passes or fails based on the first measured value corresponding to the first measurement time after adjustment by the adjustment process and the first expected value corresponding to the order at the first measurement time after the adjustment; an output process for outputting a determination result obtained by the determination process; A test program comprising:

Citation Information

Patent Citations

  • Modular code restoration method for black box industrial control system

    CN113434424A

  • Abnormality detecting method and abnormality detection device

    JP2009245228A

  • Apparatus for evaluation of test data, and program evaluation support method

    JP2011209970A

  • System, apparatus and method for detecting abnormality

    JP2020204832A

  • Verification system and verification device

    JP2010015240A