Method and system for automatically generating T2 test case of security level instrument control system
By automatically generating T2 test cases for safety-level instrumentation and control systems, the problems of low compilation efficiency, strong subjectivity, and cumbersome testing process in the existing technology are solved, efficient and accurate test case generation is achieved, and work efficiency is improved.
Patent Information
- Application Number
- CN202510809523.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-17
- Publication Date
- 2025-09-12
AI Technical Summary
In the existing technology, the compilation of T2 test cases for safety-level instrumentation and control systems is inefficient, subjective and empiricist, test items are not fully covered, and the testing process is cumbersome.
By judging whether the nuclear power plant site needs to conduct T2 testing, the prerequisites and required variables for starting the test are screened out, a signal flow graph between the input and output variables is constructed, and the algorithm blocks corresponding to the signal flow are used as segment nodes for logical verification, and finally T2 test cases are automatically generated.
It significantly improves the efficiency of generating T2 test cases, reduces the omission of signals and logic timing verification errors caused by manual screening, reduces the design waiting process, and improves the work efficiency of staff.
Smart Images

Figure CN120631776A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of software testing, and in particular to a method, system, device and medium for automatically generating T2 test cases for a safety-level instrumentation and control system. Background Art
[0002] Safety-level instrumentation and control systems (I&Cs) are critical control systems related to nuclear safety and serve as the central nervous system of nuclear power plants. Therefore, they require regular safety function testing. Currently, the compilation of T2 test cases for safety-level digital I&C systems in nuclear power plants is implemented through empirical manual programming. The designer's workflow is as follows: The design of the instrumentation and control (IC) functional diagram was completed and passed the first round of verification and validation (V&V). V&V verification is used to prove that its safety and reliability meet nuclear safety requirements. Based on the characteristics of this project, the corresponding T2 test case design guidelines were completed. Based on the I&C functional diagram, the test functions, input and output links, and test permission conditions were sorted out. Pre-test initialization was set up and test data was restored before the T2 test case was written. This approach has obvious shortcomings: 1) The manual compilation method is time-consuming and labor-intensive, requiring review, and low compilation efficiency. 2) Test cases are subjective and empirical, and the standards and specifications of test items compiled by different personnel vary. 3) Test items have incomplete coverage, and there are omissions in timing tests. 4) The test case human-machine interface is poor, the testing process is cumbersome, and repeated debugging is required. Summary of the Invention
[0003] The purpose of the present invention is to provide a method, system, device and medium for automatically generating T2 test cases for a safety-level instrumentation and control system, which can organize the corresponding signal flow diagram and automatically generate T2 test cases, reduce the omission of signals and logic timing verification errors caused by manual screening, reduce design links and other links, and improve the work efficiency of staff.
[0004] The present invention is achieved through the following technical solutions: In a first aspect, an embodiment of the present invention provides a method for automatically generating T2 test cases for a safety-level instrumentation and control system, comprising: Determine whether a nuclear power plant site needs to undergo T2 testing; If not, delete the nuclear power plant site or map page; If yes, the prerequisites for starting the test are screened out at the nuclear power plant sites where the test is required; Screen out the variables needed for the experiment; Construct the signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; Determine whether the algorithm on the segment node requires logic verification; If not, delete the segment node; If so, perform logic verification and generate T2 test cases according to the segment nodes.
[0005] Furthermore, specific methods for determining whether a nuclear power plant site needs to undergo T2 testing include: Determine whether the conditions for conducting T2 test are met at the current moment, determine the number of nuclear power plant sites that need to conduct T2 test, and determine what type of functional test the test is.
[0006] Furthermore, specific methods for screening the prerequisites for starting the test at the nuclear power plant site where the test is required include: Group by test type and summarize all drawings of the nuclear power plant site that contain test types; Search all input and output signals, all set values and all intermediate variables from the drawings, and sort out the test permission conditions.
[0007] Furthermore, all algorithm blocks encountered in the middle of the signal flow are used as segment nodes. The method includes: Search through different algorithm blocks; Read the verification logic and process corresponding to different algorithm blocks, load them by node, and the nodes correspond to the input and output signals of the algorithm block test items.
[0008] Furthermore, specific methods of logic verification include: Verification is performed by calling logic verification modules made with different algorithm blocks, adaptively adjusting the input and output signal names of segmented nodes, and generating test cases one by one in sequence.
[0009] Furthermore, the specific method of generating T2 test cases according to segment nodes includes: Fill in the test item values in the setting filling template in sequence according to the arrangement breakpoints; Perform logic review on initial value setting, check time, delay time, and logic reset to generate the final T2 test case.
[0010] In a second aspect, another embodiment of the present invention provides a safety-level instrumentation and control system T2 test case automatic generation system, comprising: a first judgment module, a screening module, a construction module, a second judgment module and a logic verification module; The first judgment module is used to judge whether the nuclear power plant site needs to perform T2 test; The screening module is used to screen out the prerequisites for starting the test and the variables required for the test at the nuclear power plant site where the test is required; The construction module is used to construct a signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; The second judgment module is used to judge whether the algorithm on the segment node requires logic verification; The logic verification module is used to perform logic verification on the algorithm on the segment nodes that need to be logically verified, and generate T2 test cases according to the segment nodes.
[0011] Furthermore, the first judgment module includes a condition judgment unit, a quantity judgment unit and a type judgment unit. The condition judgment unit is used to judge whether the conditions for carrying out the T2 test are met at the current moment; The quantity determination unit is used to determine the number of nuclear power plant sites that need to undergo T2 testing; The type determination unit is used to determine which type of functional test the test is.
[0012] Furthermore, the screening module includes a prerequisite screening unit, which groups the test types, summarizes all drawings of the nuclear power plant site containing the test type, searches for all input and output signals, all set values and all intermediate variables from the drawings, and sorts out the test permission conditions.
[0013] Furthermore, the construction module includes a segmented node construction unit, which is used to search different algorithm blocks, read the verification logic and process corresponding to different algorithm blocks, and load the nodes, and the nodes correspond to the input and output signals of the algorithm block test items.
[0014] In a third aspect, another embodiment of the present invention provides an electronic device, comprising a processor, an input device, an output device and a memory, wherein the processor is connected to the input device, the output device and the memory, respectively, the memory is used to store a computer program, the computer program includes program instructions, and the processor is configured to call the program instructions to execute the method described in the first embodiment.
[0015] In a fourth aspect, another embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein the computer program includes program instructions, and when the program instructions are executed by a processor, the processor executes the method described in the first embodiment.
[0016] Compared with the prior art, the present invention has the following advantages and beneficial effects: An embodiment of the present invention provides a method for automatically generating T2 test cases for a safety-level instrumentation and control system. The method traverses the instrumentation and control function diagrams of each site to determine whether the site requires a T2 test. At nuclear power plant sites requiring a T2 test, the method screens out the prerequisites for initiating the test and the variables required for the test. Based on the screened variables, a signal flow graph is constructed between the input and output variables. All algorithms encountered in the signal flow correspond to segment nodes. If the algorithm on the segment node requires logic verification, the segment node is deleted. If logic verification is not required, the segment node is deleted. If logic verification is required, logic verification is performed. After logic verification, an importable version of the T2 test case is automatically generated. This method can automatically generate T2 test cases for a safety-level instrumentation and control system. For designers, this method can significantly reduce the risk of missed signals and logic timing verification errors caused by manual screening, reduce design waiting times, effectively shorten design time, and improve staff work efficiency. It can also reduce tedious testing processes, significantly shorten the application software design cycle, and improve software accuracy.
[0017] The embodiments of the present invention provide a system, device, and medium for automatically generating T2 test cases for a safety-level instrumentation and control system. These are based on the same inventive concept as a method for automatically generating T2 test cases for a safety-level instrumentation and control system and have the same beneficial effects. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the following briefly introduces the drawings required for use in the examples. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be considered as limiting the scope. A person of ordinary skill in the art can also derive other relevant drawings based on these drawings without inventive effort. In the drawings: Figure 1 A flowchart of a method for automatically generating T2 test cases for a safety-level instrumentation and control system provided by the first embodiment of the present invention; Figure 2 A schematic diagram of generating an Excel version of a T2 test case and filling in the test case template in sections using the method provided by the first embodiment of the present invention; Figure 3 This is a structural block diagram of a system for automatically generating T2 test cases for a safety-level instrumentation and control system provided by another embodiment of the present invention. DETAILED DESCRIPTION
[0019] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with examples and drawings. The exemplary embodiments of the present invention and their descriptions are only used to explain the present invention and are not intended to limit the present invention.
[0020] Example 1 With the continuous advancement of the industrialization of safety-grade digital instrumentation and control systems for nuclear power plants, the trend toward intelligent, paperless production testing is becoming increasingly evident. Artificial intelligence is used to track signal flows, automatically locate input and output signals, and automatically generate test cases by orchestrating test items for each algorithm block in the chain using a predefined rule language. This design of an automated T2 test case generation method for safety-grade instrumentation and control systems effectively overcomes the drawbacks of a lengthy, inefficient, and costly T2 test case development process.
[0021] like Figure 1 As shown, the first embodiment of the present invention provides a method for automatically generating T2 test cases for a safety-level instrumentation and control system, comprising: Obtain information about HTML files in the safety-level instrumentation and control system; Determine whether the nuclear power plant site needs to conduct T2 testing based on the information in the HTML file; If not, delete the nuclear power plant site or map page; If yes, the prerequisites for starting the test are screened out at the nuclear power plant sites where the test is required; Screen out the variables needed for the experiment; Construct the signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; Determine whether the algorithm on the segment node requires logic verification; If not, delete the segment node; If so, perform logic verification and generate T2 test cases according to the segment nodes.
[0022] First, the instrumentation and control function diagrams for each station are traversed to determine whether the station requires a T2 test. Once a periodic test is determined, the type of test is determined. Examples include a shutdown logic function test, a dedicated safety device actuation function test, and an equipment control actuation function test. By using a keyword query, such as "shutdown signal output," all signals related to the shutdown function can be found along the signal flow of the function diagram. This effectively eliminates signal logic unrelated to the T2 test, such as at the TU station.
[0023] Next, determine the prerequisites for initiating the test within the identified sites. Tests are grouped, such as for a shutdown function. All drawings for that site containing that function are aggregated. Using a global parameter search, all input and output signals, set values, and intermediate variables within the specific logic function drawing group are automatically searched to identify the permissible test conditions. Signals requiring initialization during the test and their corresponding initialization values are determined.
[0024] Next, determine which variables should participate in the test. For signals with multiple outputs, select only one variable, and it's recommended to select intermediate variables. Signals on the corresponding link that are not related to the shutdown or device driver function should be eliminated. Specifically, through the secondary logic judgment of the shutdown or device driver, irrelevant branch logic can be eliminated to reduce the number of final generated use cases.
[0025] Next, construct a signal flow graph between the input and output variables. The data flow graph is used to construct the signal flow from input to output, with all algorithm blocks encountered in the middle serving as segment nodes. The signal flow from input to output can be automatically traced using link signals. By targeting specific logical functions, the logic within the same link on different drawings can be automatically sorted out to determine the logical function drawing groupings. The different algorithm blocks are searched, and the corresponding verification logic and processes are read. These are loaded at the nodes, and the corresponding input and output signals of the algorithm block test items are mapped.
[0026] Subsequently, the algorithm logic is verified. For all the segmented nodes that have been sorted out, the algorithm blocks on the nodes are logically verified. For different algorithm blocks, logic verification modules of corresponding algorithm blocks can be created to provide direct calls. When performing logic verification, verification is performed by calling logic verification modules made using different algorithm blocks, adaptively adjusting the input and output signal names of the segmented nodes, and generating test cases one by one in sequence. For example, for the threshold comparison module, it is necessary to verify whether the corresponding upper and lower thresholds can be triggered, and at the same time verify the threshold accuracy; for a device switch, it is necessary to verify the on / off state of the device separately; for the state of the trigger, when it comes to logic verification of RS and RL triggers, it should be reset first during initialization, or the logic needs to fully cover all inputs, but it is not necessary to make permutations and combinations of all inputs.
[0027] Finally, generate the T2 test case. Using a fixed entry format, enter the corresponding test item values sequentially according to the breakpoint arrangement. Perform a logical review of the initial value settings, check time, delay time, and logic reset to generate the final T2 test case. The corresponding check time (adjustable based on actual conditions) is arranged according to the table below. Finally, derive the adapted T2 test case, as shown in Table 1. During the logic review, pay attention to device initialization and post-test reset.
[0028] Table 1 T2 test case template
[0029] An embodiment of the present invention provides a method for automatically generating T2 test cases for a safety-grade instrumentation and control system. This method automatically locates input and output signals at both ends of a link by reading relevant information from an HTML file within the software for the engineer station of a nuclear power plant's safety-grade DCS platform. By reading signal parameter settings, the algorithmic logic for each input-to-output breakpoint is verified one by one. This method utilizes multiple modes for determination, classifying signals by site, system, and function through text recognition, and rapidly generating T2 test cases through segmented node logic verification.
[0030] The first embodiment of the present invention is described in further detail below with reference to specific examples. The embodiment of the present invention is based on a method for automatically tracing link signals, and takes a device control signal as an example to describe the operating status of the device.
[0031] This signal was determined to be Class 1E device control, belonging to the device control logic of a dedicated site, and therefore required to participate in the T2 test. By searching for keywords, we searched for relevant input and output signals for the AH01 and AH02 devices and found six relevant input signals and eight output signals.
[0032] Draw the entire device signal flow diagram through the input and output signals, and establish the corresponding segment nodes of the logic signal flow. Then perform logic verification based on the segment nodes. The verification sequence is as follows: analog processing → threshold comparison → voting logic → switch logic → device on / off, as shown below: 1) Due to the switching logic between the AH001 and AH002 devices, when one device switches from the running state to the stopped state, it triggers the other device to start. Therefore, the running state of the device is uncertain during the test. Therefore, during initialization, the unload signal is directly set to "1" to trigger the stop of the AH001 and AH002 devices, and all other feedbacks are set to "0"; 2) Set one of the devices to operate, AH002 to operate, AH001 to stop operating, and set the initial conditions; 3) AH002 equipment switches from operation to shutdown, triggering AH001 equipment to start, and at the same time triggering AH002 to output a stop command and close the corresponding valve of AH002; 4) After the AH001 device is started, the AH001 device operation feedback is obtained, triggering the AH001 corresponding valve to open and reset the logic to switch to AH001; 5) AH001 equipment switches from operation to shutdown, triggering AH002 equipment to start, and at the same time triggering AH001 to output a stop command and close the corresponding valve of AH001; 6) After the AH002 device is started, the AH002 device operation feedback is obtained, triggering the AH002 corresponding valve to open and reset the logic to switch to AH002; 7) Verify the SBO unloading function, set the SBO signal to "1", trigger AH001 and AH002 to stop; 8) After the AH002 device stops, it receives stop feedback, triggering the corresponding valve of AH002 to close.
[0033] Finally, generate the Excel version of the T2 test case and fill it into the test case template in sections to facilitate importing into the engineer station, such as Figure 2 shown.
[0034] An embodiment of the present invention provides a method for automatically generating T2 test cases for a safety-level instrumentation and control system. The method traverses the instrumentation and control function diagrams of each site to determine whether the site requires a T2 test. At nuclear power plant sites requiring a T2 test, the method screens out the prerequisites for initiating the test and the variables required for the test. Based on the screened variables, a signal flow graph is constructed between the input and output variables. All algorithms encountered in the signal flow correspond to segment nodes. If the algorithm on the segment node requires logic verification, the segment node is deleted. If logic verification is not required, the segment node is deleted. If logic verification is required, logic verification is performed. After logic verification, an importable version of the T2 test case is automatically generated. This method can automatically generate T2 test cases for a safety-level instrumentation and control system. For designers, this method can significantly reduce the risk of missed signals and logic timing verification errors caused by manual screening, reduce design waiting times, effectively shorten design time, and improve staff work efficiency. It can also reduce tedious testing processes, significantly shorten the application software design cycle, and improve software accuracy.
[0035] Example 2 like Figure 3 As shown, another embodiment of the present invention provides a safety-level instrumentation and control system T2 test case automatic generation system, including: a first judgment module, a screening module, a construction module, a second judgment module and a logic verification module; The first judgment module is used to judge whether the nuclear power plant site needs to perform T2 test; The screening module is used to screen out the prerequisites for starting the test and the variables required for the test at the nuclear power plant site where the test is required; The construction module is used to construct a signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; The second judgment module is used to judge whether the algorithm on the segment node requires logic verification; The logic verification module is used to perform logic verification on the algorithm on the segment nodes that need to be logically verified, and generate T2 test cases according to the segment nodes.
[0036] The first judgment module includes a condition judgment unit, a quantity judgment unit and a type judgment unit. The condition judgment unit is used to judge whether the conditions for carrying out the T2 test are met at the current moment; The quantity determination unit is used to determine the number of nuclear power plant sites that need to undergo T2 testing; The type determination unit is used to determine which type of functional test the test is.
[0037] The screening module includes a prerequisite screening unit, which groups the test types, summarizes all drawings of the nuclear power plant site containing the test type, searches for all input and output signals, all set values and all intermediate variables from the drawings, and sorts out the test permission conditions.
[0038] The construction module includes a segmented node construction unit, which is used to search different algorithm blocks, read the verification logic and process corresponding to different algorithm blocks, and load them in nodes. The nodes correspond to the input and output signals of the algorithm block test items.
[0039] The execution process of each module can be performed according to the process steps of an accelerated method for fuel cladding wear prediction in Example 1, and will not be described in detail in this embodiment.
[0040] An embodiment of the present invention provides a system for automatically generating T2 test cases for a safety-level instrumentation and control system. The system traverses the instrumentation and control function diagrams of each site to determine whether the site requires a T2 test. At nuclear power plant sites requiring a T2 test, the system screens out the prerequisites for initiating the test and the variables required for the test. Based on the screened variables, a signal flow graph is constructed between the input and output variables. All algorithms encountered in the signal flow correspond to segment nodes. If the algorithm on the segment node requires logic verification, the segment node is deleted. If logic verification is not required, the segment node is deleted. After logic verification, an importable version of the T2 test case is automatically generated. This method can automatically generate T2 test cases for a safety-level instrumentation and control system. For designers, this method can significantly reduce the risk of missed signals from manual screening and logic timing verification errors, reduce design waiting times, effectively shorten design time, and improve staff work efficiency. It can also reduce tedious testing processes, significantly shorten the application software design cycle, and improve software accuracy.
[0041] Example 3 Another embodiment of the present invention provides a structural block diagram of an electronic device, which includes a processor, an input device, an output device and a memory, the processor is connected to the input device, the output device and the memory respectively, the memory is used to store a computer program, the computer program includes program instructions, and the processor is configured to call the program instructions to execute the method described in the first embodiment above.
[0042] It should be understood that in the embodiments of the present invention, the processor referred to may be a central processing unit (CPU), and the processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.
[0043] Input devices may include a touchpad, a fingerprint sensor (for collecting the user's fingerprint information and fingerprint direction information), a microphone, etc. Output devices may include a display (LCD, etc.), a speaker, etc.
[0044] The memory may include read-only memory and random access memory, and provides instructions and data to the processor. A portion of the memory may also include non-volatile random access memory. For example, the memory may also store information about the device type.
[0045] In specific implementations, the processor, input device, and output device described in the embodiments of the present invention can execute the implementation methods described in the method embodiments provided by the embodiments of the present invention, and can also execute the implementation methods of the system embodiments described in the embodiments of the present invention, which will not be repeated here.
[0046] Example 4 Another embodiment of the present invention further provides an embodiment of a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein the computer program includes program instructions, and when the program instructions are executed by a processor, the processor executes the method described in the first embodiment.
[0047] The computer-readable storage medium may be the internal storage unit of the terminal described in the aforementioned embodiment, such as the terminal's hard disk or memory. The computer-readable storage medium may also be an external storage device of the terminal, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash memory card, etc. Furthermore, the computer-readable storage medium may include both the terminal's internal storage unit and an external storage device. The computer-readable storage medium is used to store the computer program and other programs and data required by the terminal. The computer-readable storage medium may also be used to temporarily store data that has been output or is about to be output.
[0048] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the composition and steps of each example according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0049] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the terminals and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0050] In the several embodiments provided in this application, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, or can be electrical, mechanical or other forms of connection.
[0051] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A method for automatically generating T2 test cases for a safety-level instrumentation and control system, characterized in that: include: Determine whether a nuclear power plant site needs to undergo T2 testing; If not, delete the nuclear power plant site or map page; If yes, the prerequisites for starting the test are screened out at the nuclear power plant sites where the test is required; Screen out the variables needed for the experiment; Construct the signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; Determine whether the algorithm on the segment node requires logic verification; If not, delete the segment node; If so, perform logic verification and generate T2 test cases according to the segment nodes.
2. The method according to claim 1, characterized in that The specific method for determining whether a nuclear power plant site needs to undergo a T2 test includes: Determine whether the conditions for conducting T2 test are met at the current moment, determine the number of nuclear power plant sites that need to conduct T2 test, and determine what type of functional test the test is.
3. The method according to claim 2, characterized in that The specific method for screening the prerequisites for starting the test at the nuclear power plant site where the test is required includes: Group by test type and summarize all drawings of the nuclear power plant site that contain test types; Search all input and output signals, all set values and all intermediate variables from the drawings, and sort out the test permission conditions.
4. The method according to claim 3, characterized in that The method of treating all algorithm blocks encountered in the middle of the signal flow as segment nodes includes: Search through different algorithm blocks; Read the verification logic and process corresponding to different algorithm blocks, load them by node, and the nodes correspond to the input and output signals of the algorithm block test items.
5. The method according to claim 4, characterized in that The specific method of the logic verification includes: Verification is performed by calling logic verification modules made with different algorithm blocks, adaptively adjusting the input and output signal names of segmented nodes, and generating test cases one by one in sequence.
6. The method according to claim 5, characterized in that The specific method of generating T2 test cases according to segment nodes includes: Fill in the test item values in the setting filling template in sequence according to the arrangement breakpoints; Perform logic review on initial value setting, check time, delay time, and logic reset to generate the final T2 test case.
7. A safety-level instrumentation and control system T2 test case automatic generation system, characterized by: include: a first judgment module, a screening module, a construction module, a second judgment module and a logic verification module; The first judgment module is used to judge whether the nuclear power plant site needs to perform T2 test; The screening module is used to screen out the prerequisites for starting the test and the variables required for the test at the nuclear power plant site where the test is required; The construction module is used to construct a signal flow from input variables to output variables according to the data flow graph, and use all algorithm blocks encountered in the middle of the signal flow as segment nodes; The second judgment module is used to judge whether the algorithm on the segment node requires logic verification; The logic verification module is used to perform logic verification on the algorithm on the segment nodes that need to be logically verified, and generate T2 test cases according to the segment nodes.
8. The system according to claim 7, wherein: The first judgment module includes a condition judgment unit, a quantity judgment unit and a type judgment unit. The condition judgment unit is used to judge whether the conditions for carrying out the T2 test are met at the current moment; The quantity determination unit is used to determine the number of nuclear power plant sites that need to undergo T2 testing; The type determination unit is used to determine which type of functional test the test is.
9. The system according to claim 8, wherein The screening module includes a prerequisite screening unit, which groups the test types, summarizes all drawings of the nuclear power plant site containing the test type, searches for all input and output signals, all set values and all intermediate variables from the drawings, and sorts out the test permission conditions.
10. The system according to claim 9, wherein: The construction module includes a segmented node construction unit, which is used to search different algorithm blocks, read the verification logic and process corresponding to different algorithm blocks, and load them in nodes. The nodes correspond to the input and output signals of the corresponding algorithm block test items.
11. An electronic device comprising a processor, an input device, an output device, and a memory, wherein the processor is connected to the input device, the output device, and the memory respectively, and the memory is used to store a computer program, wherein the computer program comprises program instructions, and wherein: The processor is configured to call the program instructions and execute the method according to any one of claims 1 to 6.
12. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, wherein the computer program includes program instructions. When the program instructions are executed by a processor, the processor is caused to perform the method according to any one of claims 1 to 6.