Test efficiency improving method and system for factory mode and storage medium
By using an adaptive matching model and multi-level threshold comparison technology, the problems of hardware adaptation, cumbersome manual operation, and scattered result recording in factory mode testing are solved, realizing the automation and accuracy of the testing process and improving testing efficiency and reliability.
Patent Information
- Application Number
- CN202511744684.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-25
- Publication Date
- 2026-02-27
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing factory-mode testing solutions lack hardware adaptability, requiring testers to manually modify source code. Test execution relies on cumbersome and time-consuming manual operations and lacks error-proofing mechanisms. Test results are scattered and difficult to trace, hindering the improvement of production line testing efficiency and reliability.
By using the adaptive matching model of the feature configuration file, test item queues and threshold groups are automatically generated. Real-time data acquisition and multi-level threshold comparison are performed. The introduction of error-proof logic control and disabling of interface buttons builds an automated testing closed loop, realizing full automation and precise management of the testing process.
It achieves full automation of the testing process, reduces manual intervention, improves the consistency and reliability of testing, ensures the traceability of test results, and enhances the production line's quality optimization capabilities.
Smart Images

Figure CN121579288A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of test efficiency improvement, and more specifically, to a method, system, and storage medium for improving test efficiency in factory mode. Background Technology
[0002] With the increasing complexity of smart terminal device manufacturing, rapid and accurate testing of the hardware functions of the entire device in the factory production process has become a key technical challenge in ensuring product quality. Existing factory-mode testing solutions generally suffer from systemic defects, severely restricting the improvement of production line testing efficiency and reliability. First, traditional testing solutions lack hardware adaptability. Due to differences in hardware modules across different device models, testers must manually modify the test application source code to adapt to various device configurations. This not only significantly increases development workload but also makes it difficult for the testing solution to quickly respond to changes in the production line. Second, the test execution process is highly dependent on manual operation. Production line personnel must click through the test interface item by item to complete functional verification. The entire process is cumbersome and time-consuming, and prone to missed tests or misjudgments due to operator fatigue. Third, existing test items generally lack effective error-proofing mechanisms. During testing, it is impossible to prevent operational errors such as accidentally clicking the pass button, leading to faulty equipment flowing into subsequent stages. Finally, the recording of test results is fragmented and lacks a systematic approach, making it difficult to form traceable quality analysis data and hindering continuous optimization of production line processes. Therefore, there is an urgent need for a large-scale testing efficiency improvement technology that can achieve automated testing, intelligent error prevention, and adaptability. Summary of the Invention
[0003] In view of the above problems, the purpose of this invention is to provide a method, system, and storage medium for improving testing efficiency in factory mode. This method automatically generates test queues by matching hardware characteristics in response to device power-on signals, and dynamically executes and judges test items based on a chain threshold comparison mechanism, constructing a complete automated testing closed loop and eliminating efficiency bottlenecks and operational errors caused by manual intervention. Specifically, firstly, by parsing XML configurations and sorting test item dependencies, plug-and-play test schemes and optimized execution logic are achieved, solving the source code modification problem in multi-device adaptation. Secondly, by precisely driving hardware modules and collecting real-time data, the reliability and timeliness of test data sources are ensured, providing a solid foundation for threshold decisions. Thirdly, by using a multi-level threshold sequential comparison and immediate termination mechanism, single judgments are deepened into a hierarchical decision chain, improving the ability to identify complex hardware faults. Simultaneously, by using foolproof logic control and linked disabling of interface buttons, rigid protection against abnormal states is constructed, preventing quality vulnerabilities caused by misoperation. Finally, by using structured storage of test data and process logs, a complete quality traceability chain is formed, providing data support for production line optimization.
[0004] The first aspect of this invention provides a method for improving testing efficiency in factory mode, the method comprising: In response to the power-on startup signal, an adaptive matching model based on the feature profile is used to obtain a test item queue and a test item threshold group. In response to the test start command, the current test item is determined according to the test item queue, the current test data is collected, and the threshold group of the test item is extracted to obtain the threshold sequence; Based on the sequential comparison results between the current test data and the threshold sequence, the determination result of the current test item is obtained; If the determination result is failure, then exit the test and send a disable button command to the view layer; If the determination result is passed, then the next test item is loaded according to the test item queue until all test items are completed; The judgment results and process logs for each test item are saved to non-volatile memory.
[0005] In this scheme, the adaptive matching model based on feature configuration files obtains a test item queue and a test item threshold group, specifically including: Based on the device hardware identifier and the pre-stored XML configuration file, the set of test item identifiers corresponding to the current device hardware module is parsed out; Based on the set of test item identifiers and the preset test item dependencies, an ordered queue of test items is obtained by prioritizing the test items according to the preset test item priority. Based on the identifier of each test item and the threshold definition in the configuration file, the threshold sequence corresponding to each test item is extracted and combined to obtain the test item threshold group.
[0006] In this scheme, the step of determining the current test item based on the test item queue, collecting the current test data, and extracting the test item threshold group to obtain the threshold sequence specifically includes: Based on the test start command and the current pointer position of the test item queue, determine the current test item to be executed; Based on the hardware module identifier corresponding to the current test item, activate the corresponding hardware module to enter the test state; Based on the activated hardware module and preset sampling parameters, multiple real-time test data for the current test item are obtained through real-time data acquisition and processing. Based on the current test item identifier, extract the test item threshold group to obtain a threshold sequence arranged in the comparison order.
[0007] In this scheme, the step of obtaining the judgment result of the current test item based on the sequential comparison results of the current test data and the threshold sequence specifically includes: The first-level comparison result is obtained by comparing the real-time test data value with the first-level threshold in the threshold sequence. When the first-level comparison result is passed, the second-level comparison result is obtained by comparing the real-time test data value with the second-level threshold in the threshold sequence. Perform threshold comparisons at subsequent levels sequentially; A pass result is obtained when all threshold comparisons at all levels pass. If the threshold comparison at any level fails, a failure result is obtained immediately.
[0008] In this solution, if the determination result is a failure, the test is exited and a disable button instruction is sent to the view layer, specifically including: Based on the failure judgment result and the current test item status, and using the preset error prevention mechanism, interface control instructions are generated. According to the interface control instructions, send a disable instruction for the target operation button to the view layer; Based on the failure result, exit the current automated testing process and return to the test item selection interface.
[0009] In this solution, saving the judgment results and process logs of each test item to non-volatile memory specifically includes: Based on the final judgment result of each test item, and in accordance with the preset test result structure logic, a test record is generated, including the test item identifier, judgment result, and timestamp. Based on the detailed comparison data during the threshold comparison process, and in accordance with the preset log generation rules, a process log containing the threshold comparison status at each level is created. Based on the test records and process logs, the structured data is then saved to a database or file system.
[0010] A second aspect of the present invention provides a test efficiency improvement system for factory mode, including a test efficiency improvement method program for factory mode, wherein the test efficiency improvement method program for factory mode, when executed by the processor, performs the following steps: In response to the power-on startup signal, an adaptive matching model based on the feature profile is used to obtain a test item queue and a test item threshold group. In response to the test start command, the current test item is determined according to the test item queue, the current test data is collected, and the threshold group of the test item is extracted to obtain the threshold sequence; Based on the sequential comparison results between the current test data and the threshold sequence, the determination result of the current test item is obtained; If the determination result is failure, then exit the test and send a disable button command to the view layer; If the determination result is passed, then the next test item is loaded according to the test item queue until all test items are completed; The judgment results and process logs for each test item are saved to non-volatile memory.
[0011] A third aspect of the present invention provides a computer-readable storage medium including a test efficiency improvement method program for factory mode, wherein when the test efficiency improvement method program for factory mode is executed by a processor, the test efficiency improvement method program for factory mode as described in any of the preceding claims implements the steps of the test efficiency improvement method for factory mode.
[0012] This invention provides a method, system, and storage medium for improving testing efficiency in factory mode. By responding to the device's power-on signal and using an adaptive matching model based on feature profiles, it dynamically generates a queue of test items and threshold groups corresponding to the current device's hardware characteristics. Upon triggering a test command, it collects real-time test data and compares it sequentially with a preset threshold sequence, performing multi-level threshold judgments. If any level fails, the test is immediately terminated and marked as failed. Simultaneously, a foolproof design at the view layer disables accidental button operations. If a test item passes, the next item is automatically loaded until the queue is complete. All test results and detailed logs are persistently stored. This achieves full automation and precise control of the testing process while ensuring the traceability of test results, providing technical support for production line quality optimization. Attached Figure Description
[0013] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly described below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope.
[0014] Figure 1 A flowchart of a method for improving test efficiency in factory mode according to the present invention is shown; Figure 2 The flowchart of an adaptive matching model provided by an embodiment of the present invention is shown; Figure 3 This diagram illustrates a flowchart of test data acquisition and threshold sequence extraction for a current test item, provided by an embodiment of the present invention. Figure 4 A block diagram of a test efficiency improvement system for factory mode according to the present invention is shown. Detailed Implementation
[0015] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0016] Unless otherwise defined, all terms (including technical and scientific terms) used in embodiments of this invention shall have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. It should also be understood that terms such as those defined in a common dictionary shall be interpreted as having a meaning consistent with their meaning in the context of the relevant art, and not as being interpreted in an idealized or highly formalized sense, unless expressly defined in this embodiment of the invention.
[0017] The terms "first," "second," and similar words used in the embodiments of this invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "an," "a," or "the" do not indicate a quantity limitation, but rather indicate the presence of at least one. Similarly, terms such as "including" or "comprising" mean that the element or object preceding the word encompasses the elements or objects listed after the word and their equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. The steps preceding or following the steps in the method of the embodiments of this invention are not necessarily performed precisely in sequence. Instead, various steps can be processed in reverse order or simultaneously. Furthermore, other operations can be added to these processes, or one or more steps can be removed from these processes.
[0018] In addition, the functional modules in the various embodiments of the present invention can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0019] Figure 1 A flowchart of a method for improving test efficiency in factory mode according to the present invention is shown.
[0020] like Figure 1 As shown, the first aspect of the present invention discloses a method for improving testing efficiency in factory mode, the method comprising: S102, in response to the power-on start signal, obtains the test item queue and test item threshold group based on the adaptive matching model of the feature profile; S104, in response to the test start command, determine the current test item according to the test item queue, collect the current test data, and extract the test item threshold group to obtain the threshold sequence; S106, Based on the sequential comparison results between the current test data and the threshold sequence, the determination result of the current test item is obtained; S108, If the determination result is failure, then exit the test and send a disable button instruction to the view layer; S110, if the determination result is passed, then load the next test item according to the test item queue until all test items are completed; S112, save the judgment results and process log of each test item to non-volatile memory.
[0021] It should be noted that, in this embodiment, in response to the device power-on signal, the device hardware features are automatically identified through an adaptive matching model of the feature profile (such as a hardware feature adaptive matching algorithm), dynamically generating a corresponding test item queue and a threshold group associated with each test item. Subsequently, in response to the test start command, the current test item is located according to the queue order, driving the corresponding hardware module to enter the test state and collect real-time test data; at the same time, a preset threshold sequence is extracted. Then, the real-time test data and the threshold sequence are compared sequentially and orderly, forming a chain decision chain. Only when the threshold of the current level is met will the comparison proceed to the next level; if any level fails, the process immediately terminates and the test item is marked as failed. If the test item passes, the next item is automatically loaded until the queue is complete; if it fails, a command is sent to the view layer to disable the success operation button to achieve foolproof control. Finally, the judgment results of all test items and detailed comparison process logs are structured and saved to non-volatile memory. This embodiment achieves fully automated and precise management of the testing process through the synergistic effect of hardware adaptive configuration, cascading threshold decision-making, automated process control, and mistake-proof design, reducing manual intervention and improving the consistency and reliability of testing; at the same time, it ensures the traceability of test results and continuous optimization of production line quality.
[0022] Figure 2 The flowchart of an adaptive matching model provided by an embodiment of the present invention is shown.
[0023] According to embodiments of the present invention, such as Figure 2 As shown, the adaptive matching model based on feature configuration files obtains a queue of test items and a set of test item thresholds, specifically including: S202, based on the device hardware identifier and the pre-stored XML configuration file, parse out the set of test item identifiers corresponding to the current device hardware module; S204. Based on the set of test item identifiers and the preset test item dependencies, and according to the preset test item priority sorting, an ordered test item queue is obtained. S206. Based on the identifier of each test item and the threshold definition in the configuration file, extract the threshold sequence corresponding to each test item, and combine them to obtain the test item threshold group.
[0024] It should be noted that in this embodiment, the pre-stored XML configuration file is first retrieved based on the device's unique hardware identifier. The mapping relationship between hardware modules and test items defined in the configuration file is parsed to generate a set of test item identifiers specific to the current device. Then, according to the preset dependency relationships and execution priority rules between test items, the set of test item identifiers is sorted and optimized for scheduling, forming an ordered test item queue to ensure the logical rationality and execution efficiency of the test process. Furthermore, for each test item in the queue, multiple threshold parameters corresponding to it are extracted from the configuration file and combined into an ordered threshold sequence according to the comparison logic order, forming a complete test item threshold group. This embodiment achieves precise adaptation between the test plan and the device hardware characteristics through a dynamic parsing and sorting mechanism, avoiding the manual code modification required due to device differences in traditional methods; at the same time, dependency optimization improves the coherence and execution efficiency of the test process, laying a structured foundation for subsequent chain threshold comparisons.
[0025] Figure 3 The flowchart illustrates a test data acquisition and threshold sequence extraction process for a current test item, as provided in an embodiment of the present invention.
[0026] According to embodiments of the present invention, such as Figure 3 As shown, the step of determining the current test item based on the test item queue, collecting the current test data, and extracting the test item threshold group to obtain the threshold sequence specifically includes: S302, determine the current test item to be executed based on the test start command and the current pointer position of the test item queue; S304. Based on the hardware module identifier corresponding to the current test item, activate the corresponding hardware module to enter the test state; S306, based on the activated hardware module and preset sampling parameters, obtains multiple real-time test data for the current test item through real-time data acquisition and processing; S308, Based on the current test item identifier, extract the test item threshold group to obtain a threshold sequence arranged in the comparison order.
[0027] It should be noted that, in this embodiment, upon receiving the test start command, the test item to be executed is located based on the current pointer position of the test item queue; and the corresponding hardware driver is activated based on the hardware module identifier bound to the test item, bringing it into a testable state. Subsequently, real-time data is collected from the activated hardware module using preset sampling frequency and data format parameters to obtain a multi-dimensional test data sequence reflecting its working status. Simultaneously, the corresponding ordered threshold sequence is extracted from the loaded test item threshold group based on the current test item identifier, ensuring that the threshold order in subsequent comparison stages is strictly consistent with the test logic. This embodiment ensures the accuracy and timeliness of test data through the automatic invocation of hardware drivers and the standardization of real-time data collection. Furthermore, the dynamic extraction of threshold sequences supports the personalized evaluation needs of different test items, providing reliable data input and judgment basis for chain threshold comparisons.
[0028] According to an embodiment of the present invention, obtaining the determination result of the current test item based on the sequential comparison results of the current test data and the threshold sequence specifically includes: The first-level comparison result is obtained by comparing the real-time test data value with the first-level threshold in the threshold sequence. When the first-level comparison result is passed, the second-level comparison result is obtained by comparing the real-time test data value with the second-level threshold in the threshold sequence. Perform threshold comparisons at subsequent levels sequentially; A pass result is obtained when all threshold comparisons at all levels pass. If the threshold comparison at any level fails, a failure result is obtained immediately.
[0029] It should be noted that in this embodiment, a multi-level chain comparison mechanism is initiated using a real-time test data sequence and a preset ordered threshold sequence as input. First, the real-time data is matched against the first-level threshold in the threshold sequence. If the condition is met, the comparison proceeds to the second-level threshold, and so on, level by level. This process forms a strict sequential decision chain; if any level of comparison fails, subsequent comparisons are immediately interrupted, and a failure result is generated. A test item is only considered passed when all threshold conditions at all levels are met. This embodiment, by introducing an ordered chain threshold comparison logic, deepens the traditional single judgment into a multi-condition, hierarchical comprehensive evaluation, effectively identifying complex or hidden hardware faults and improving the depth and accuracy of testing. Simultaneously, the immediate termination mechanism prevents invalid testing from continuing, optimizing test resource allocation and execution efficiency.
[0030] According to an embodiment of the present invention, if the determination result is a failure, the step of exiting the test and sending a disable button instruction to the view layer specifically includes: Based on the failure judgment result and the current test item status, and using the preset error prevention mechanism, interface control instructions are generated. According to the interface control instructions, send a disable instruction for the target operation button to the view layer; Based on the failure result, exit the current automated testing process and return to the test item selection interface.
[0031] It should be noted that in this embodiment, the system immediately initiates a specific interface control command based on a preset error-proofing logic mechanism after a test item is determined to have failed. This command, once sent to the view layer, forcibly disables the "success" or similar confirmation buttons (e.g., graying them out), thus completely eliminating the possibility of testers mistakenly judging a test as passed from the interaction level. Simultaneously, the running automated test pipeline is automatically terminated, the control flow exits the current test environment, and precisely returns to the test item selection interface, providing operators with a clear entry point for problem localization. This embodiment, through a hardware-software integrated error-proofing design and an immediate process interruption mechanism, constructs a closed-loop processing path for abnormal test results; it not only effectively prevents incorrect recording of test results due to human error but also ensures the rigor of the test process and the authority of the test data; thereby comprehensively improving the quality control level of production line testing.
[0032] According to an embodiment of the present invention, saving the judgment results and process logs of each test item to non-volatile memory specifically includes: Based on the final judgment result of each test item, and in accordance with the preset test result structure logic, a test record is generated, including the test item identifier, judgment result, and timestamp. Based on the detailed comparison data during the threshold comparison process, and in accordance with the preset log generation rules, a process log containing the threshold comparison status at each level is created. Based on the test records and process logs, the structured data is then saved to a database or file system.
[0033] It should be noted that in this embodiment, execution begins immediately after any test item is judged. The unique identifier of the test item, the final judgment result, and the precise timestamp are encapsulated into a standardized test record according to a predefined structured format. Simultaneously, the status information at each level during the threshold chain comparison process is captured and recorded in detail, generating a process log containing the complete decision path. Finally, the structured test records and process logs are uniformly written to a database or file system and other non-volatile storage media through a data persistence interface. This embodiment achieves full lifecycle traceability of test behavior through standardized encapsulation of test data and full-process log recording, providing a detailed and reliable data foundation for analysis, fault mode statistics, and process improvement. This enhances the precision of quality management for subsequent production line quality analysis.
[0034] It is worth mentioning that it also includes: Retrieve historical test records stored in non-volatile memory, and obtain the historical pass rate of each test item threshold based on a preset test data statistical analysis model; Based on the historical pass rate and a preset threshold adjustment strategy, a threshold correction sequence is generated and used to update the threshold sequence. The threshold definitions in the feature profile are dynamically adjusted based on the device hardware identifier and the updated threshold sequence.
[0035] It should be noted that in this embodiment, historical test records accumulated in non-volatile memory are accessed periodically, and a statistical analysis model is used to calculate the historical pass rate of each test item threshold. Then, a threshold correction sequence is generated based on a preset threshold adjustment strategy (such as dynamic calibration based on pass rate deviation), and this sequence is used to dynamically update the original threshold definition in the feature configuration file. This embodiment provides a test system with self-learning and continuous optimization capabilities, enabling threshold parameters to adaptively adjust as production line processes mature and hardware batches change; effectively avoiding overly stringent or lenient testing problems caused by threshold fixation, thereby continuously improving test accuracy and production line applicability.
[0036] It is worth mentioning that it also includes: Obtain the hardware module dependencies of each test item in the test item queue, and identify combinations of test items with dependencies based on a preset dependency analysis model; Based on the identified test item combinations, and using a preset test sequence adjustment mechanism, the execution order of the test items is rearranged to eliminate conflicts; When executing the current test item, verify according to the preset preconditions and check whether the hardware modules with dependencies are in a ready state; If a test is detected as not being ready, the current test item is skipped and the reason for skipping is recorded. The test item continues to be executed for subsequent non-dependent test items.
[0037] It should be noted that in this embodiment, after the test queue is initialized, a hardware module dependency analysis is performed on each test item in the queue. By identifying combinations of test items with conflicting execution conditions or sequential dependencies, the execution order of the test items is rearranged to eliminate potential conflicts. Before executing a specific test item, it is verified whether its dependent hardware modules are in a ready state; if the verification fails, the current item is automatically skipped and the reason is recorded, while subsequent undependent test items continue to be executed. This embodiment improves the intelligence and robustness of the testing process through pre-validation of dependencies and intelligent scheduling, avoiding process deadlocks caused by resource conflicts or unmet conditions, and ensuring the maximum execution of test tasks.
[0038] It is worth mentioning that it also includes: Extract the fluctuation characteristics of the real-time collected test data, and determine whether the current test environment is stable based on the preset test stability evaluation model; If the test environment is determined to be unstable, adjust the data acquisition frequency or increase the number of sampling points.
[0039] It should be noted that in this embodiment, during real-time data acquisition, the fluctuation characteristics of the data stream are monitored and analyzed simultaneously. Based on a stability assessment model, it is determined whether there is abnormal interference in the current test environment. When the environment is determined to be unstable, an automatic parameter adaptive adjustment mechanism is triggered to obtain more sufficient data samples by increasing the data acquisition frequency or increasing the number of sampling points, thereby offsetting the impact of environmental fluctuations on the representativeness of a single sample. This embodiment enhances the anti-interference capability of the test system under non-ideal operating conditions by introducing environmental awareness and parameter adaptive adjustment mechanisms, ensuring the consistency and reliability of test results, and improving the overall robustness of production line testing.
[0040] Figure 4 A block diagram of a test efficiency improvement system for factory mode according to the present invention is shown.
[0041] like Figure 4 As shown, a second aspect of the present invention discloses a test efficiency improvement system 4 for factory mode, including a memory 41 and a processor 42. The memory includes a test efficiency improvement method program for factory mode. When the test efficiency improvement method program for factory mode is executed by the processor, it performs the following steps: In response to the power-on startup signal, an adaptive matching model based on the feature profile is used to obtain a test item queue and a test item threshold group. In response to the test start command, the current test item is determined according to the test item queue, the current test data is collected, and the threshold group of the test item is extracted to obtain the threshold sequence; Based on the sequential comparison results between the current test data and the threshold sequence, the determination result of the current test item is obtained; If the determination result is failure, then exit the test and send a disable button command to the view layer; If the determination result is passed, then the next test item is loaded according to the test item queue until all test items are completed; The judgment results and process logs for each test item are saved to non-volatile memory.
[0042] It should be noted that, in this embodiment, in response to the device power-on signal, the device hardware features are automatically identified through an adaptive matching model of the feature profile (such as a hardware feature adaptive matching algorithm), dynamically generating a corresponding test item queue and a threshold group associated with each test item. Subsequently, in response to the test start command, the current test item is located according to the queue order, driving the corresponding hardware module to enter the test state and collect real-time test data; at the same time, a preset threshold sequence is extracted. Then, the real-time test data and the threshold sequence are compared sequentially and orderly, forming a chain decision chain. Only when the threshold of the current level is met will the comparison proceed to the next level; if any level fails, the process immediately terminates and the test item is marked as failed. If the test item passes, the next item is automatically loaded until the queue is complete; if it fails, a command is sent to the view layer to disable the success operation button to achieve foolproof control. Finally, the judgment results of all test items and detailed comparison process logs are structured and saved to non-volatile memory. This embodiment achieves fully automated and precise management of the testing process through the synergistic effect of hardware adaptive configuration, cascading threshold decision-making, automated process control, and mistake-proof design, reducing manual intervention and improving the consistency and reliability of testing; at the same time, it ensures the traceability of test results and continuous optimization of production line quality.
[0043] According to an embodiment of the present invention, the adaptive matching model based on feature profiles, which obtains a test item queue and a test item threshold group, specifically includes: Based on the device hardware identifier and the pre-stored XML configuration file, the set of test item identifiers corresponding to the current device hardware module is parsed out; Based on the set of test item identifiers and the preset test item dependencies, an ordered queue of test items is obtained by prioritizing the test items according to the preset test item priority. Based on the identifier of each test item and the threshold definition in the configuration file, the threshold sequence corresponding to each test item is extracted and combined to obtain the test item threshold group.
[0044] It should be noted that in this embodiment, the pre-stored XML configuration file is first retrieved based on the device's unique hardware identifier. The mapping relationship between hardware modules and test items defined in the configuration file is parsed to generate a set of test item identifiers specific to the current device. Then, according to the preset dependency relationships and execution priority rules between test items, the set of test item identifiers is sorted and optimized for scheduling, forming an ordered test item queue to ensure the logical rationality and execution efficiency of the test process. Furthermore, for each test item in the queue, multiple threshold parameters corresponding to it are extracted from the configuration file and combined into an ordered threshold sequence according to the comparison logic order, forming a complete test item threshold group. This embodiment achieves precise adaptation between the test plan and the device hardware characteristics through a dynamic parsing and sorting mechanism, avoiding the manual code modification required due to device differences in traditional methods; at the same time, dependency optimization improves the coherence and execution efficiency of the test process, laying a structured foundation for subsequent chain threshold comparisons.
[0045] According to an embodiment of the present invention, the step of determining the current test item based on the test item queue, collecting the current test data, and extracting the test item threshold group to obtain the threshold sequence specifically includes: Based on the test start command and the current pointer position of the test item queue, determine the current test item to be executed; Based on the hardware module identifier corresponding to the current test item, activate the corresponding hardware module to enter the test state; Based on the activated hardware module and preset sampling parameters, multiple real-time test data for the current test item are obtained through real-time data acquisition and processing. Based on the current test item identifier, extract the test item threshold group to obtain a threshold sequence arranged in the comparison order.
[0046] It should be noted that, in this embodiment, upon receiving the test start command, the test item to be executed is located based on the current pointer position of the test item queue; and the corresponding hardware driver is activated based on the hardware module identifier bound to the test item, bringing it into a testable state. Subsequently, real-time data is collected from the activated hardware module using preset sampling frequency and data format parameters to obtain a multi-dimensional test data sequence reflecting its working status. Simultaneously, the corresponding ordered threshold sequence is extracted from the loaded test item threshold group based on the current test item identifier, ensuring that the threshold order in subsequent comparison stages is strictly consistent with the test logic. This embodiment ensures the accuracy and timeliness of test data through the automatic invocation of hardware drivers and the standardization of real-time data collection. Furthermore, the dynamic extraction of threshold sequences supports the personalized evaluation needs of different test items, providing reliable data input and judgment basis for chain threshold comparisons.
[0047] According to an embodiment of the present invention, obtaining the determination result of the current test item based on the sequential comparison results of the current test data and the threshold sequence specifically includes: The first-level comparison result is obtained by comparing the real-time test data value with the first-level threshold in the threshold sequence. When the first-level comparison result is passed, the second-level comparison result is obtained by comparing the real-time test data value with the second-level threshold in the threshold sequence. Perform threshold comparisons at subsequent levels sequentially; A pass result is obtained when all threshold comparisons at all levels pass. If the threshold comparison at any level fails, a failure result is obtained immediately.
[0048] It should be noted that in this embodiment, a multi-level chain comparison mechanism is initiated using a real-time test data sequence and a preset ordered threshold sequence as input. First, the real-time data is matched against the first-level threshold in the threshold sequence. If the condition is met, the comparison proceeds to the second-level threshold, and so on, level by level. This process forms a strict sequential decision chain; if any level of comparison fails, subsequent comparisons are immediately interrupted, and a failure result is generated. A test item is only considered passed when all threshold conditions at all levels are met. This embodiment, by introducing an ordered chain threshold comparison logic, deepens the traditional single judgment into a multi-condition, hierarchical comprehensive evaluation, effectively identifying complex or hidden hardware faults and improving the depth and accuracy of testing. Simultaneously, the immediate termination mechanism prevents invalid testing from continuing, optimizing test resource allocation and execution efficiency.
[0049] According to an embodiment of the present invention, if the determination result is a failure, the step of exiting the test and sending a disable button instruction to the view layer specifically includes: Based on the failure judgment result and the current test item status, and using the preset error prevention mechanism, interface control instructions are generated. According to the interface control instructions, send a disable instruction for the target operation button to the view layer; Based on the failure result, exit the current automated testing process and return to the test item selection interface.
[0050] It should be noted that in this embodiment, the system immediately initiates a specific interface control command based on a preset error-proofing logic mechanism after a test item is determined to have failed. This command, once sent to the view layer, forcibly disables the "success" or similar confirmation buttons (e.g., graying them out), thus completely eliminating the possibility of testers mistakenly judging a test as passed from the interaction level. Simultaneously, the running automated test pipeline is automatically terminated, the control flow exits the current test environment, and precisely returns to the test item selection interface, providing operators with a clear entry point for problem localization. This embodiment, through a hardware-software integrated error-proofing design and an immediate process interruption mechanism, constructs a closed-loop processing path for abnormal test results; it not only effectively prevents incorrect recording of test results due to human error but also ensures the rigor of the test process and the authority of the test data; thereby comprehensively improving the quality control level of production line testing.
[0051] According to an embodiment of the present invention, saving the judgment results and process logs of each test item to non-volatile memory specifically includes: Based on the final judgment result of each test item, and in accordance with the preset test result structure logic, a test record is generated, including the test item identifier, judgment result, and timestamp. Based on the detailed comparison data during the threshold comparison process, and in accordance with the preset log generation rules, a process log containing the threshold comparison status at each level is created. Based on the test records and process logs, the structured data is then saved to a database or file system.
[0052] It should be noted that in this embodiment, execution begins immediately after any test item is judged. The unique identifier of the test item, the final judgment result, and the precise timestamp are encapsulated into a standardized test record according to a predefined structured format. Simultaneously, the status information at each level during the threshold chain comparison process is captured and recorded in detail, generating a process log containing the complete decision path. Finally, the structured test records and process logs are uniformly written to a database or file system and other non-volatile storage media through a data persistence interface. This embodiment achieves full lifecycle traceability of test behavior through standardized encapsulation of test data and full-process log recording, providing a detailed and reliable data foundation for analysis, fault mode statistics, and process improvement. This enhances the precision of quality management for subsequent production line quality analysis.
[0053] It is worth mentioning that it also includes: Retrieve historical test records stored in non-volatile memory, and obtain the historical pass rate of each test item threshold based on a preset test data statistical analysis model; Based on the historical pass rate and a preset threshold adjustment strategy, a threshold correction sequence is generated and used to update the threshold sequence. The threshold definitions in the feature profile are dynamically adjusted based on the device hardware identifier and the updated threshold sequence.
[0054] It should be noted that in this embodiment, historical test records accumulated in non-volatile memory are accessed periodically, and a statistical analysis model is used to calculate the historical pass rate of each test item threshold. Then, a threshold correction sequence is generated based on a preset threshold adjustment strategy (such as dynamic calibration based on pass rate deviation), and this sequence is used to dynamically update the original threshold definition in the feature configuration file. This embodiment provides a test system with self-learning and continuous optimization capabilities, enabling threshold parameters to adaptively adjust as production line processes mature and hardware batches change; effectively avoiding overly stringent or lenient testing problems caused by threshold fixation, thereby continuously improving test accuracy and production line applicability.
[0055] It is worth mentioning that it also includes: Obtain the hardware module dependencies of each test item in the test item queue, and identify combinations of test items with dependencies based on a preset dependency analysis model; Based on the identified test item combinations, and using a preset test sequence adjustment mechanism, the execution order of the test items is rearranged to eliminate conflicts; When executing the current test item, verify according to the preset preconditions and check whether the hardware modules with dependencies are in a ready state; If a test is detected as not being ready, the current test item is skipped and the reason for skipping is recorded. The test item continues to be executed for subsequent non-dependent test items.
[0056] It should be noted that in this embodiment, after the test queue is initialized, a hardware module dependency analysis is performed on each test item in the queue. By identifying combinations of test items with conflicting execution conditions or sequential dependencies, the execution order of the test items is rearranged to eliminate potential conflicts. Before executing a specific test item, it is verified whether its dependent hardware modules are in a ready state; if the verification fails, the current item is automatically skipped and the reason is recorded, while subsequent undependent test items continue to be executed. This embodiment improves the intelligence and robustness of the testing process through pre-validation of dependencies and intelligent scheduling, avoiding process deadlocks caused by resource conflicts or unmet conditions, and ensuring the maximum execution of test tasks.
[0057] It is worth mentioning that it also includes: Extract the fluctuation characteristics of the real-time collected test data, and determine whether the current test environment is stable based on the preset test stability evaluation model; If the test environment is determined to be unstable, adjust the data acquisition frequency or increase the number of sampling points.
[0058] It should be noted that in this embodiment, during real-time data acquisition, the fluctuation characteristics of the data stream are monitored and analyzed simultaneously. Based on a stability assessment model, it is determined whether there is abnormal interference in the current test environment. When the environment is determined to be unstable, an automatic parameter adaptive adjustment mechanism is triggered to obtain more sufficient data samples by increasing the data acquisition frequency or increasing the number of sampling points, thereby offsetting the impact of environmental fluctuations on the representativeness of a single sample. This embodiment enhances the anti-interference capability of the test system under non-ideal operating conditions by introducing environmental awareness and parameter adaptive adjustment mechanisms, ensuring the consistency and reliability of test results, and improving the overall robustness of production line testing.
[0059] A third aspect of the present invention provides a computer-readable storage medium including a test efficiency improvement method program for factory mode, wherein when the test efficiency improvement method program for factory mode is executed by a processor, the test efficiency improvement method program for factory mode as described in any of the preceding claims implements the steps of the test efficiency improvement method for factory mode.
[0060] In summary, this invention provides a method, system, and storage medium for improving testing efficiency in factory mode. By responding to the device's power-on signal and using an adaptive matching model based on feature configuration files, it dynamically generates a queue of test items and threshold groups corresponding to the current device's hardware characteristics. Upon triggering a test command, it collects real-time test data and compares it sequentially with a preset threshold sequence, performing multi-level threshold judgments. If any level fails, the test is immediately terminated and marked as failed. Simultaneously, a foolproof design at the view layer disables accidental button operations. If a test item passes, the next item is automatically loaded until the queue is complete. All test results and detailed logs are persistently stored. This achieves full automation and precise control of the testing process while ensuring the traceability of test results, providing technical support for production line quality optimization.
[0061] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0062] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for test efficiency improvement for factory pattern, characterized in that, The method comprises: in response to a power-on start signal, obtaining a test item queue and a test item threshold value group based on an adaptive matching model of a feature configuration file; in response to a test start instruction, determining a current test item according to the test item queue, obtaining current test data, and extracting a threshold value sequence from the test item threshold value group; obtaining a determination result of the current test item according to a comparison result of the current test data and the threshold value sequence in sequence; if the determination result is failure, exiting the test and sending a disable button instruction to a view layer; if the determination result is pass, loading a next test item according to the test item queue until all test items are completed; saving the determination result of each test item and a process log to a non-volatile memory.
2. The method for improving test efficiency for factory pattern according to claim 1, wherein, The adaptive matching model based on the feature configuration file obtains the test item queue and the test item threshold value group, and specifically comprises: parsing a test item identifier set corresponding to a current device hardware module according to a device hardware identifier and a pre-stored XML configuration file; obtaining an ordered test item queue based on a preset test item priority order according to the test item identifier set and a preset test item dependency relationship; extracting a threshold value sequence corresponding to each test item according to each test item identifier and a threshold value definition in the configuration file, and combining to obtain the test item threshold value group.
3. The method for improving test efficiency for factory pattern according to claim 1, wherein, The method specifically comprises: determining a current test item to be executed according to a test start instruction and a current pointer position of the test item queue; activating a corresponding hardware module into a test state according to a hardware module identifier corresponding to the current test item; obtaining a plurality of real-time test data of the current test item based on real-time data acquisition processing according to the activated hardware module and a preset sampling parameter; extracting the test item threshold value group according to the current test item identifier to obtain a threshold value sequence arranged in a comparison order.
4. The method for improving test efficiency for factory pattern according to claim 1, wherein, The method specifically comprises: comparing a real-time test data value and a first-level threshold value in the threshold value sequence to obtain a first-level comparison result; when the first-level comparison result is pass, comparing a real-time test data value and a second-level threshold value in the threshold value sequence to obtain a second-level comparison result; sequentially performing threshold value comparison of subsequent levels; when threshold value comparison of all levels is pass, obtaining a pass determination result; when threshold value comparison of any level fails, immediately obtaining a failure determination result.
5. The method for test efficiency improvement for factory pattern according to claim 1, wherein, The method specifically comprises: generating an interface control instruction based on a preset foolproof mechanism according to the failure determination result and a current test item state; sending a disable instruction of a target operation button to the view layer according to the interface control instruction; exiting a current automated test process according to the failure determination result and returning to a test item selection interface.
6. The method for test efficiency improvement for factory pattern according to claim 1, wherein, The method specifically comprises: According to the final determination result of each test item, a test record is generated according to a preset test result structured logic, including test item identification, determination result and time stamp; According to the detailed comparison data in the threshold comparison process, a process log containing threshold comparison states at all levels is created according to a preset log generation rule; According to the test record and the process log, structured data is saved to a database or a file system.
7. A test efficiency improvement system for a factory pattern, characterized by, The system comprises a memory and a processor, the memory comprising a test efficiency improvement method program for factory mode, the test efficiency improvement method program for factory mode being executed by the processor to implement the following steps: In response to a power-on start signal, a test item queue and a test item threshold group are obtained based on an adaptive matching model of a feature configuration file; In response to a test start instruction, a current test item is determined according to the test item queue, current test data is obtained by collection, and a threshold sequence is obtained by extracting the test item threshold group; A determination result of the current test item is obtained according to the sequential comparison result of the current test data and the threshold sequence; If the determination result is failure, the test is exited and a disable button instruction is sent to the view layer; If the determination result is pass, the next test item is loaded according to the test item queue until all test items are completed; The determination results of the test items and the process log are saved to a non-volatile memory.
8. The test efficiency improvement system for factory pattern of claim 7, wherein, The adaptive matching model based on the feature configuration file obtains the test item queue and the test item threshold group, specifically including: According to the device hardware identifier and the pre-stored XML configuration file, a test item identification set corresponding to the current device hardware module is parsed and obtained; According to the test item identification set and the preset test item dependency relationship, an ordered test item queue is obtained based on the preset test item priority sorting; According to each test item identification and the threshold definition in the configuration file, a threshold sequence corresponding to each test item is extracted and obtained, and a test item threshold group is obtained by combination.
9. The test efficiency improvement system for factory pattern of claim 7, wherein, The determination of the current test item according to the test item queue, the obtaining of the current test data by collection, and the obtaining of the threshold sequence by extracting the test item threshold group, specifically include: According to the test start instruction and the current pointer position of the test item queue, the current test item to be executed is determined; According to the hardware module identification corresponding to the current test item, the corresponding hardware module is activated to enter a test state; According to the activated hardware module and the preset sampling parameter, a plurality of real-time test data of the current test item is obtained based on real-time data collection and processing; According to the current test item identification, the test item threshold group is extracted to obtain a threshold sequence arranged in comparison order.
10. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer readable storage medium comprises a test efficiency improvement method program for factory mode, the test efficiency improvement method program for factory mode being executed by the processor to implement the steps of the test efficiency improvement method for factory mode according to any one of claims 1 to 6.