Multi-platform compatibility automatic testing method and system
By constructing a three-dimensional heterogeneous correlation graph and using dynamic attention mechanisms and graph neural networks to identify risks, combined with an edge-cloud collaborative testing architecture, the problem of cross-dimensional feature fragmentation in multi-platform compatibility testing is solved, achieving accurate test coverage and risk positioning for scenarios with multiple hardware architectures and operating system combinations.
Patent Information
- Application Number
- CN202511515545.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-22
- Publication Date
- 2026-01-09
AI Technical Summary
Existing technologies suffer from fragmented processing of user behavior sequences, system resource interaction data, and underlying platform feature data in multi-platform compatibility testing. This makes it difficult to achieve collaborative analysis of cross-dimensional features, accurately identify compatibility risks and trace the root cause chain of risks, and result in insufficient test coverage, making it difficult to meet the accurate testing needs of scenarios with multiple hardware architectures and multiple operating system combinations.
By establishing causal relationships between user behavior sequences, system resource interaction data, and underlying platform feature data of test equipment through a time-series alignment algorithm, a three-dimensional heterogeneous correlation graph is constructed. Risk identification is performed using a dynamic attention mechanism and an enhanced graph neural network with time-series graph convolution, generating deep compatibility test cases. An edge-cloud collaborative shadow test architecture is deployed for verification and analysis, and adaptive identification is performed by combining the modular structure of the backbone graph neural network and the platform adaptation branch.
It achieves accurate test coverage for scenarios with multiple hardware architectures and operating systems, avoids wasting resources on low-risk scenarios, ensures that test accuracy continues to improve as the platform expands, and completely solves the problems of vague risk positioning and insufficient test coverage.
Smart Images

Figure CN121301209A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of compatibility testing, and in particular to an automated method and system for multi-platform compatibility testing. Background Technology
[0002] In multi-platform compatibility testing, existing technologies generally suffer from the problem of fragmented processing of user behavior sequences, system resource interaction data, and underlying platform characteristic data—neither establishing temporal causal relationships between the three types of data nor achieving collaborative analysis of cross-dimensional features. This makes it difficult to accurately identify compatibility risks that require the linkage of these three factors during testing (such as stuttering caused by the coupling of memory allocation mechanisms and operating system API call rules on ARM architecture devices due to specific user operations), and after a risk occurs, it is impossible to trace the complete root cause chain of "behavior triggering - resource consumption - platform characteristics," resulting in insufficient test coverage, vague risk positioning, and difficulty in meeting the accurate testing needs of scenarios with multiple hardware architectures and multiple operating systems.
[0003] As can be seen from the above, how to achieve accurate testing in scenarios with multiple hardware architectures and multiple operating systems remains to be solved. Summary of the Invention
[0004] To meet the accurate testing needs of scenarios with multiple hardware architectures and multiple operating systems, this application provides a multi-platform compatibility automated testing method and system.
[0005] Firstly, this application provides a multi-platform compatibility automated testing method, which adopts the following technical solution: A multi-platform compatibility automated testing method includes: Acquire multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test equipment underlying platform feature data. Establish causal relationships among the three types of data through a time-series alignment algorithm, and generate a three-dimensional heterogeneous association graph containing four types of association edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information. Risk identification is performed based on the aforementioned three-dimensional heterogeneous correlation graph by fusing dynamic attention mechanism and temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform node, and assigns dynamic weights to the nodes in combination with the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operator, the high-risk behavior sequence and the corresponding risk probability are output. Based on the high-risk behavior sequence, a test case gene library with an operation atom-parameter matrix-expected result ternary structure is constructed to obtain the user behavior frequency corresponding to the user. Based on the underlying feature data of the platform node, the test parameters are adaptively adjusted. A priority scoring model is constructed by combining the user behavior frequency and the risk probability to generate deep compatibility test cases. Deploy an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. Functional consistency is verified by comparing the feature values of the output results. Differences in system resource consumption are screened based on dynamic thresholds to obtain corresponding difference analysis results. The relationships between heterogeneous graph nodes and attention weights are correlated, risk-contributing nodes are traced in reverse, and a complete risk root cause chain of behavior-resource-platform is generated. A modular structure of backbone graph neural network + platform adaptation branch is adopted. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the test data of the new platform. The test data of the new platform includes operation logs, system resource consumption data and output results. Historical key risk samples are retained through memory replay mechanism. Based on the data of the new platform and the difference analysis results, the compatibility risk of the new platform is adaptively identified by adjusting the dynamic threshold.
[0006] Optionally, in establishing causal relationships among the three types of data using a time-series alignment algorithm, the method further includes: Set the duration of the sliding time window, and perform time slicing on user behavior sequence data and system resource interaction data based on the sliding time window; calculate the mutual information entropy of behavior operations and resource consumption within the same time window, set the corresponding mutual information entropy filtering threshold, and select strongly correlated data pairs based on the mutual information entropy filtering threshold; Static attribute annotation is performed on the underlying platform feature data, which includes hardware architecture model and OS kernel version. The annotated underlying platform feature data is bound to strongly correlated data pairs through timestamp mapping to generate a three-dimensional heterogeneous correlation map. Attribute annotation is performed on nodes in a 3D heterogeneous correlation graph, specifying the operation type and duration for behavior node annotation.
[0007] Optionally, in the process of calculating the platform risk coefficient using the dynamic attention mechanism, the method further includes: Construct a mapping library corresponding to hardware architecture, operating system, and historical failures. Based on the mapping library, calculate the compatibility failure rate under each hardware architecture and operating system combination. Divide the combination into high-risk and low-risk combinations according to the compatibility failure rate, and configure a higher basic risk coefficient for high-risk combinations than for low-risk combinations. The quantitative factor corresponding to the scope of influence of the behavior is calculated. The quantitative factor is determined based on the ratio of the number of resource nodes triggered by the behavior node to the total number of resource nodes. The quantitative factor changes positively with the increase or decrease of the ratio of the number of triggered resource nodes. The initial platform risk coefficient is calculated by multiplying the basic risk coefficient and the quantitative factor of the scope of influence of the behavior. When a platform node OSAPI has a version compatibility vulnerability, and the authenticity of the version compatibility vulnerability is confirmed by matching and verification through the vulnerability database, a preset risk compensation value is added to the initial platform risk coefficient. The value of the preset risk compensation value must ensure that the added value can effectively distinguish the platform risk difference between platforms with API version compatibility vulnerabilities and those without version compatibility vulnerabilities, and finally obtain the corresponding platform risk coefficient.
[0008] Optionally, in the process of constructing the ternary structure of the atom-parameter matrix-expected result, the method further includes: A clustering algorithm based on behavioral patterns maps high-frequency user behavior sequences into sets of operation atoms. The clustering algorithm performs clustering based on the duration of user behavior, operation frequency, and resource consumption patterns. The generation of the parameter matrix is combined with the system resource consumption sensitivity analysis, and a dynamic parameter range is set for memory-sensitive operations. The dynamic parameter range is adaptively adjusted based on the underlying feature data of the platform node. The expected results are generated using behavior-resource joint constraint modeling. The modeling process includes: extracting key constraints based on historical risk root cause chains, and dynamically adjusting the tolerance range of the expected results in conjunction with the compatibility scores of platform nodes.
[0009] Optionally, the preliminary verification mechanism for edge nodes may further include: Deploy a lightweight inference model to perform real-time feature extraction on replicated user requests. Real-time feature extraction includes pattern recognition of behavioral sequences and anomaly detection of resource consumption. An incremental anomaly detection algorithm is used to identify sudden changes in resource consumption at the edge. The incremental anomaly detection algorithm dynamically updates the anomaly threshold to adapt to the resource fluctuation characteristics under different platform architectures. The initial verification results are uploaded to the cloud test cluster via the MQTT protocol. The edge nodes only upload the verification data of high-risk behavior sequences to reduce the communication load between the edge and the cloud.
[0010] Optionally, in the process of screening resource consumption differences in a dynamic threshold screening system, the method further includes: A multidimensional distribution model is constructed based on historical resource consumption data to dynamically calculate the normal range threshold of resource consumption. By comparing the resource consumption data of the cloud testing environment and the preliminary edge verification, the chi-square test is used to determine the significance of the differences, and the difference analysis results are generated based on the significance level. By associating heterogeneous graph node relationships and attention weights, risk-contributing nodes are tracked through a backpropagation algorithm. The backpropagation algorithm combines the platform risk coefficient and the behavioral impact range quantification factor to generate a complete risk root cause chain of behavior-resource-platform.
[0011] Secondly, this application provides a multi-platform compatibility automated testing system, which adopts the following technical solution: A multi-platform compatibility automated testing system includes: The causal graph construction module acquires multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test equipment underlying platform feature data. It establishes causal relationships among the three types of data through a time-series alignment algorithm, generating a three-dimensional heterogeneous correlation graph containing four types of correlation edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information. The dynamic risk identification and probability prediction module identifies risks based on the three-dimensional heterogeneous correlation graph by integrating a dynamic attention mechanism and an enhanced graph neural network with temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform node and assigns dynamic weights to the nodes in combination with the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operators, the module outputs high-risk behavior sequences and corresponding risk probabilities. The test case adaptive generation module constructs a test case gene library with an operation atom-parameter matrix-expected result ternary structure based on the high-risk behavior sequence, obtains the user behavior frequency corresponding to the user, adaptively adjusts the test parameters based on the underlying feature data of the platform node, and constructs a priority scoring model by combining the user behavior frequency and the risk probability to generate deep compatibility test cases. The edge-cloud collaborative shadow testing module deploys an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. The module verifies functional consistency by comparing the feature values of the output results, obtains corresponding difference analysis results by screening differences in system resource consumption based on dynamic thresholds, associates heterogeneous graph node relationships and attention weights, traces risk-contributing nodes in reverse, and generates a complete risk root cause chain of behavior-resource-platform. The platform adaptive model update module adopts a modular structure of backbone graph neural network + platform adaptation branch. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the newly added platform test data. The newly added platform test data includes operation logs, system resource consumption data and output results. Historical key risk samples are retained through memory replay mechanism, and adaptive identification of new platform compatibility risks is achieved through dynamic threshold adjustment based on the new platform data and difference analysis results.
[0012] Thirdly, this application provides a multi-platform compatibility automated testing system, which adopts the following technical solution: A multi-platform compatibility automated testing system includes a processor, wherein the processor runs a program of any one of the multi-platform compatibility automated testing methods described above.
[0013] Fourthly, this application provides a storage medium, which adopts the following technical solution: A storage medium storing a program for the multi-platform compatibility automated testing method described in any one of the above.
[0014] In summary, this application includes at least one of the following beneficial technical effects: By integrating user behavior sequences, system resource interactions, and underlying platform feature data through a time-series alignment algorithm, a three-dimensional heterogeneous association graph containing three types of nodes—behavior, resources, and platform—is constructed. The dynamic attention mechanism is used to accurately calculate the platform risk coefficient, and high-priority test cases are generated based on user behavior frequency and risk probability. This achieves accurate coverage of scenarios with multiple hardware architectures and operating system combinations, avoiding the problem of wasting resources on low-risk scenarios in traditional testing.
[0015] The edge-cloud collaborative shadow testing architecture verifies high-risk behavior sequences in milliseconds in real production environments. The cloud dynamically constructs a test environment matrix and associates it with heterogeneous graphs to trace the root cause chain. The modular structure of the backbone network and platform adaptation branches, combined with a memory replay mechanism, identifies new platform compatibility risks through dynamic threshold adaptive identification, ensuring that test accuracy continues to improve as the platform expands. This completely solves the problems of ambiguous risk positioning and insufficient test coverage under multi-platform combinations. Attached Figure Description
[0016] Figure 1 This is a flowchart illustrating an automated testing method for multi-platform compatibility according to an exemplary embodiment.
[0017] Figure 2 This is a structural block diagram of a multi-platform compatibility automated testing system according to an exemplary embodiment. Detailed Implementation
[0018] The embodiments of this application are described in detail below, and examples of the embodiments are shown in the accompanying drawings.
[0019] In the description of this specification, the references to "certain embodiments," "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples" refer to specific features, structures, materials, or characteristics described in connection with the described embodiment or example, which are included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0020] This application discloses an automated testing method for multi-platform compatibility, referring to... Figure 1 ,include: S100 acquires multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test device underlying platform feature data. It establishes causal relationships among the three types of data through a time-series alignment algorithm, generating a three-dimensional heterogeneous association graph containing four types of association edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information.
[0021] The execution process of S100 specifically includes: Step 1, Data Collection and Classification: User behavior sequence data (such as clicks, swipes, and input operations) is collected in real-time during application runtime using event tracking technology. The operation type, duration, and trigger order are recorded to form a structured behavior sequence. Simultaneously, resource interaction data (including CPU utilization, memory usage, and network request latency) is dynamically captured using a system monitoring framework (such as the Linuxperf tool). This precisely correlates resource consumption changes for each behavior (e.g., "clicking the payment button" corresponds to "memory usage +150MB"). Furthermore, underlying platform characteristic data of the test device is extracted through the device information API, covering hardware architecture (such as ARMv8 / Intelx86), operating system version, and key kernel parameters. This ensures that the three types of data are systematically classified in terms of dimension, granularity, and real-time performance, providing a complete data foundation for subsequent causal correlation.
[0022] Step 2, Time-Sequence Alignment Algorithm Processing: A timestamp-based dynamic alignment algorithm is used to address the issue of differences in the frequency of heterogeneous data collection. This involves unifying the timestamp benchmark across all data sources (e.g., nanosecond-level system clocks) and precisely aligning behavioral sequences and resource interaction data along the timeline. An adaptive sliding window mechanism is introduced (the window size is dynamically adjusted to 1.5 times the duration of the behavior, e.g., a 2-second operation corresponds to a 300ms window), slicing the data into continuous time segments to ensure a strong temporal correlation between behavior and resource changes within the same window. By calculating the mutual information entropy between behavioral operations and resource consumption, strongly correlated event pairs with mutual information entropy exceeding a threshold (e.g., 0.8) are selected (e.g., "5 consecutive clicks" and "a sudden increase of 100MB in memory usage"), eliminating weakly correlated data and significantly improving the accuracy of data alignment and the effectiveness of causal relationships.
[0023] Step 3, Construction of a 3D Heterogeneous Association Graph: Based on the aligned data, a 3D heterogeneous association graph is constructed, comprising action nodes, resource nodes, platform nodes, and four types of association edges. Action nodes are labeled with operation type (e.g., "clicking the WeChat payment button") and duration (e.g., "1.8 seconds"). Resource nodes are labeled with resource type (e.g., "memory") and consumption value (e.g., "+120MB"). Platform nodes are labeled with hardware architecture (e.g., "ARMv8") and operating system version (e.g., "Android 13"). Association edges are defined as follows: triggering edges indicate that the action directly causes resource changes (e.g., "click → memory increase"). Dependency edges indicate resource dependencies (e.g., "memory increase → CPU load increase"). Temporal edges indicate the temporal order of actions and resources (e.g., "action A completion triggers resource B change"). Compatibility edges indicate the compatibility association between platform characteristics and actions / resources (e.g., "payment operation under ARMv8 + Android 13 combination leads to memory leak"). This forms a complete causal network, transforming multi-dimensional data from an isolated state into a quantifiable and traceable association system.
[0024] S200 performs risk identification based on a three-dimensional heterogeneous correlation graph by integrating a dynamic attention mechanism and an enhanced graph neural network with temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform nodes and assigns dynamic weights to the nodes based on the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operators, the high-risk behavior sequence and the corresponding risk probability are output.
[0025] The execution process of S200 specifically includes: Step 1: The dynamic attention mechanism handles the platform's risk coefficient and behavior weight allocation. Platform risk coefficient calculation: Based on platform nodes (e.g., "ARMv8 + Android 13") in the 3D heterogeneous correlation graph, feature vectors of hardware architecture and operating system combinations (e.g., memory management strategies, API compatibility versions) are extracted. Using a pre-trained mapping library (e.g., historical failure rate statistics), the basic risk coefficient for each platform combination is calculated (e.g., "ARMv8 + Android 13" has a high proportion of memory leak issues, so the basic risk coefficient is set to 0.85).
[0026] Quantification of the scope of impact of behavior: Analyze the proportion of resource nodes triggered by behavior nodes (such as "continuous clicking of the payment button") to the total number of resource nodes (e.g., triggering memory, CPU, and network resources accounts for 60% of all resources), and calculate the quantification factor of the scope of impact of behavior (e.g., 0.6). Generate the initial platform risk coefficient by multiplying the basic risk coefficient by the quantification factor (0.85 × 0.6 = 0.51).
[0027] Dynamic weight allocation: When a platform node is found to have a known API version compatibility vulnerability (such as confirming a WebView interface defect in Android 13 through vulnerability database matching), a preset compensation value (such as +0.2) is added to the initial risk coefficient, ultimately generating a platform risk coefficient (such as 0.71). At the same time, based on the influence range of the behavior node, the node priority is dynamically allocated through an attention weight matrix (such as setting the weight of high-risk behavior nodes to 0.9 and low-risk nodes to 0.3).
[0028] Step 2: Time-series graph convolution aggregates features and performs cross-type interactions: 1D-CNN Temporal Feature Extraction: 1D-CNN convolution operations are performed on the features of subgraph nodes in different time windows (e.g., 100ms) of heterogeneous graphs to extract temporal patterns of behavior-resource-platform (e.g., time series features of "continuous clicks → memory surge → increased CPU load"). The convolution kernel size is dynamically adjusted according to the complexity of the behavior (e.g., 3×1 small kernels for simple operations, 5×1 large kernels for complex interactions) to preserve key temporal features.
[0029] Cross-type interaction of graph convolution operators: Gated graph neural networks (GGNN) are used to realize feature interaction between cross-type nodes (behavioral nodes and resource nodes, platform nodes). For example, the interaction strength between the behavioral node "payment operation" and the resource node "memory usage" is dynamically adjusted through a gating mechanism (such as when memory usage suddenly increases, the gating weight is automatically increased to 0.9), while the risk coefficient (0.71) of the platform node "ARMv8+Android13" is integrated to generate cross-modal feature representation.
[0030] Step 3, High-risk behavior sequence identification and probability output: Risk sequence clustering and ranking: Based on the output of the enhanced graph neural network, high-risk behavior sequences (such as "continuous payment operation → memory leak → lag") are identified through clustering algorithms (such as DBSCAN) and ranked by dynamic attention weights (such as arranging them from high to low risk probability).
[0031] Risk probability quantification: The softmax function is used to normalize the node features, output the risk probability of high-risk behavior sequences (e.g., "the probability of continuous payment operation lag on ARMv8+Android13 devices is 82%), and generate risk labels (e.g., "high risk" and "medium risk").
[0032] By jointly optimizing the dynamic attention mechanism and the temporal graph convolution, the platform risk coefficient, the scope of behavioral influence and temporal features are deeply integrated, which solves the problem of insufficient accuracy of traditional methods in cross-platform and cross-modal risk identification.
[0033] S300 constructs a test case gene library with a three-element structure of operation atom-parameter matrix-expected result based on high-risk behavior sequences, obtains the frequency of user behavior corresponding to the user, adaptively adjusts test parameters based on the underlying feature data of platform nodes, and constructs a priority scoring model by combining user behavior frequency and risk probability to generate deep compatibility test cases.
[0034] The execution process of S300 specifically includes: Step 1: Constructing the three-element structure of operation atom – parameter matrix – expected result: High-risk behavior sequences (such as "continuous clicks on the payment button") are mapped to sets of operation atoms (such as "payment operation atoms") using behavior pattern clustering algorithms (such as spatiotemporal clustering based on DBSCAN). Clustering is based on factors including operation duration (such as 1.5–2.5 seconds), operation frequency (such as more than 5 times per minute), and resource consumption patterns (such as a sudden increase in memory usage of 100MB). The generation of the parameter matrix is combined with system resource consumption sensitivity analysis (such as the resource fluctuation coefficient of memory-sensitive operations), targeting the underlying characteristics of different platform nodes (…). For example, the Bionic memory management mechanism of the ARM architecture adaptively adjusts the parameter range (e.g., the memory parameter of the ARM architecture is set to 50-200MB, and the x86 architecture is set to 100-300MB); the generation of expected results adopts behavior-resource joint constraint modeling (e.g., extracting "memory leak triggering conditions" based on historical risk root cause chains), and dynamically adjusts the tolerance range of expected results (e.g., the tolerance is expanded from ±5% to ±15%) in combination with the platform node compatibility score (e.g., the Android13 compatibility score is 75 points), forming a three-element structure use case gene library of "operation atom - parameter matrix - expected result".
[0035] Step 2, User Behavior Frequency Acquisition and Test Parameter Adaptive Adjustment: Acquire user behavior frequency data (e.g., log analysis shows an average daily trigger frequency of 1200 payment operations), and adaptively adjust test parameters based on platform node underlying characteristic data (e.g., Android 13's Zygote process scheduling strategy). For example, for high-frequency operations, dynamically increase the number of test loops from 100 to 500, and lower the memory allocation threshold from 150MB to 100MB. Combining user behavior frequency and platform characteristics, calculate dynamic parameter values using a parameter sensitivity function (formula: parameter range = basic range × (1 + 0.1 × frequency coefficient)) to ensure that test parameters accurately match actual user behavior patterns and platform characteristics.
[0036] Step 3, Priority Scoring Model Construction and Deep Test Case Generation: Combining user behavior frequency (e.g., 1200 payment operations per day) and risk probability (e.g., 82% probability of lag with ARMv8+Android13 combination), a priority scoring model is constructed (formula: score = behavior frequency × risk probability × platform risk coefficient, e.g., 1200 × 0.82 × 0.71 = 694.32); based on the scoring results, deep compatibility test cases are generated (e.g., "For ARMv8+Android13 combination, with high-frequency payment operations (1200 times per day), set memory parameters of 50-200MB, the expected result is no lag and memory usage fluctuation ≤10%), and sorted by score from high to low, prioritizing the generation of test cases for high-risk combinations).
[0037] By constructing a three-element test case gene library of operation atoms, parameter matrices, and expected results, and adaptively adjusting test parameters based on user behavior frequency and platform underlying characteristics, and accurately generating deep compatibility test cases based on a priority scoring model of behavior frequency × risk probability × platform risk coefficient, high-risk scenarios with multiple hardware architectures and operating system combinations are achieved, significantly improving the efficiency of test resource allocation and the accuracy of risk identification.
[0038] S400 deploys an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. Functional consistency is verified by comparing the feature values of the output results. Differences in system resource consumption are screened based on dynamic thresholds to obtain corresponding difference analysis results. The relationships between heterogeneous graph nodes and attention weights are correlated, risk-contributing nodes are traced in reverse, and a complete risk root cause chain of behavior-resource-platform is generated.
[0039] The execution process of S400 specifically includes: Step 1, Millisecond-level Replication and Local Preliminary Verification at Edge Nodes: Edge nodes capture user requests for high-risk behavioral sequences (such as payment operations) in real time, replicate the requests in milliseconds using a lightweight inference model (such as TensorFlowLite), and perform local preliminary verification. Based on behavioral sequence pattern recognition (such as continuous click detection) and abnormal resource consumption detection (such as memory surge threshold), an incremental anomaly detection algorithm is used to dynamically update the threshold (such as memory fluctuation range ±15% under ARM architecture). Only high-risk verification data (such as abnormal results) is uploaded to the cloud via the MQTT protocol, significantly reducing the edge-cloud communication load.
[0040] Step 2, Cloud-based test environment construction and parallel execution: The cloud dynamically constructs a test environment matrix (such as virtual machine combinations) based on the underlying feature data of platform nodes (such as the hardware architecture and OS kernel parameters of ARMv8+Android13), receives edge verification data and executes deep compatibility test cases in parallel; it synchronously collects running logs (such as API call sequences), system resource consumption data (such as CPU / memory curves) and output results (such as UI rendering status) to ensure that the test environment is highly consistent with the characteristics of real devices.
[0041] Step 3, Difference Analysis and Risk Root Cause Chain Generation: Confirm functional consistency by comparing the feature values of the output results (e.g., verifying the consistency of functional API response codes); construct a multidimensional distribution model based on historical resource data, calculate dynamic thresholds (e.g., 95% confidence interval for memory consumption), and screen for significant differences in resource consumption using the chi-square test (p<0.05); associate heterogeneous graph node relationships and attention weights (e.g., platform risk coefficient 0.71), and combine the backpropagation algorithm to track risk contribution nodes (e.g., "ARMv8+Android13 payment operation triggers memory leak") to generate a complete risk root cause chain of behavior-resource-platform (e.g., "API version vulnerability → memory leak → lag").
[0042] By adopting an edge-cloud collaborative shadow testing architecture, millisecond-level real-time verification and in-depth analysis of high-risk behavior sequences are achieved, avoiding the latency and resource waste of traditional testing. The dynamically constructed test environment matrix in the cloud is precisely adapted to multiple platform combinations. Combined with dynamic thresholds and heterogeneous graph correlation analysis, it accurately locates cross-dimensional risk root causes (such as API compatibility vulnerabilities in ARM architecture + Android 13), ensuring that compatibility issues in scenarios with multiple hardware architectures and operating system combinations are efficiently and accurately identified and fixed.
[0043] The S500 adopts a modular structure of a backbone graph neural network and a platform adaptation branch. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the test data of the new platform. The test data of the new platform includes the running log, system resource consumption data and output results. Historical key risk samples are retained through a memory replay mechanism, and the new platform compatibility risk is adaptively identified by adjusting the dynamic threshold based on the data of the new platform and the difference analysis results.
[0044] The execution process of S500 specifically includes: Step 1, Modular application of the backbone network and platform adaptation branch: The backbone network extracts general risk features based on the general feature learning results of the enhanced graph neural network (such as cross-platform behavior-resource interaction patterns); the platform adaptation branch fine-tunes the parameters for new platform test data (such as running logs, system resource consumption data, output results), and adapts to the characteristics of the new platform (such as the differences in memory management strategies of Android 14) through the gradient update mechanism. Only a small amount of new data is needed to complete the rapid migration of the model and avoid full retraining.
[0045] Step 2, Historical Risk Sample Replay and Dynamic Threshold Adjustment: By using a memory replay mechanism (such as storing historical key risk samples in a replay buffer, such as the memory leak case of ARMv8+Android13), the characteristic representation of high-risk scenarios is preserved; combined with the test data of the new platform and the results of difference analysis (such as the significant difference of resource consumption chi-square test p value <0.05), the risk threshold is dynamically adjusted (such as expanding the memory leak detection threshold from ±10% to ±15%) to ensure the accuracy of risk identification on the new platform.
[0046] Step 3, Adaptive Risk Identification and Continuous Model Optimization: Based on the fine-tuned platform adaptation branch, real-time identification of new platform compatibility risks (such as calculating the probability of API call risks in Android 14) is performed, the risk probability is output and the risk root cause chain is updated; through a continuous learning mechanism, newly identified risk samples (such as network request anomalies in iOS 17) are included in the historical database, the memory replay strategy is optimized, and the model's generalization ability and identification efficiency on new platforms are improved.
[0047] Through a modular structure of backbone network + platform adaptation branches, millisecond-level adaptive identification of compatibility risks on new platforms is achieved, avoiding the high cost of retraining models in traditional methods. The memory replay mechanism and dynamic threshold adjustment ensure that the accuracy of risk identification continues to improve as the platform expands, completely solving the scalability bottleneck of test coverage in scenarios with multiple hardware architectures and operating system combinations, and enabling the compatibility testing system to have continuous evolution capabilities.
[0048] Based on the solution of this application embodiment, taking the continuous payment operation of a mobile payment application on an ARMv8 architecture Android13 device as an example, S100 collects the user's "continuous clicks on the payment button" behavior sequence (lasting 1.8 seconds) in real time through the tracking technology. The system monitoring captures a sudden increase in memory usage of 120MB. The platform feature extraction is the combination of "ARMv8 + Android13". After the time sequence alignment algorithm, strongly correlated data with a mutual information entropy of 0.85 is selected. The dynamic attention mechanism of S200 calculates the basic risk coefficient of the platform to be 0.85. Combined with the scope of the behavior's impact (triggers 3 types of resources), the initial risk is 0.51. After superimposing WebView interface vulnerability compensation, a risk coefficient of 0.71 is generated. The time sequence graph convolution identifies the high-risk sequence of "continuous clicks → memory surge → lag" and outputs a risk probability of 82%, accurately locating the compatibility defects of specific operations under the ARM architecture.
[0049] Based on this risk sequence, the S300 constructs a ternary structured test case gene library: the operation atom "continuous clicks for payment," with the parameter matrix adaptively set to a memory range of 50-200MB for the ARM architecture, and the expected result tolerance extended to ±15%. A priority scoring model (1200 times per day × 82% × 0.71 = 694.32) generates deep test cases. The S400 deploys an edge-cloud architecture, with edge nodes replicating payment requests locally for millisecond-level verification, and the cloud building an ARMv8 + Android13 test environment for parallel execution. Chi-square tests (p<0.05) are used to screen for differences in memory consumption, and a heterogeneous graph is associated to generate a root cause chain "API version vulnerability → memory leak → lag," achieving precise risk location and remediation.
[0050] The S500 retains historical risk samples from ARMv8+Android13 via the backbone network, fine-tunes parameters for newly added Android14 platform data in the platform adaptation branch, and dynamically adjusts the memory leak threshold (±10%→±15%) through a memory replay mechanism. Only 50 test data points are needed to complete adaptive risk identification for new platforms. This solution enables the system to form a closed loop from risk localization (S200) to test execution (S400) and platform expansion (S500) in multiple ARM / x86 and Android / iOS scenarios, improving the efficiency of compatibility issue discovery by 40% and achieving 92% accuracy in test cases. It completely solves the inefficient bottleneck of "one test per device" in traditional methods.
[0051] In this embodiment of the application, the method for establishing causal relationships among three types of data using a time-series alignment algorithm is specifically as follows: In the timing alignment of step 1 in S100, the dynamic sliding window (behavior duration 1.8 seconds × 1.5 = 2.7 seconds) ensures that the complete cycle of the behavior operation is accurately captured, avoiding fragmentation of resource consumption changes due to an excessively small window (such as the 2.7-second window covering the click, memory surge, and the entire UI rendering process in the payment operation); the mutual information entropy threshold of 0.8 is set based on historical risk data statistics (such as the average mutual information entropy of memory operation under ARM architecture is 0.75), accurately filtering out strongly correlated events such as "continuous clicks of the payment button" (mutual information entropy 0.85) and "sudden increase in memory usage of 100MB", and eliminating weakly correlated data (such as the mutual information entropy of sliding operation and CPU fluctuation of 0.4), so that the three-dimensional heterogeneous spectrum retains only high-confidence causal chains, providing a clean data base for subsequent analysis.
[0052] The underlying platform characteristics (ARMv8 architecture, Android 13 kernel) are annotated with static attributes and then bound to strongly correlated data pairs via nanosecond-level timestamp mapping. For example, at timestamp t, when a "payment operation" triggers a "memory surge" event, the platform characteristic "ARMv8 + Android 13" is annotated to the associated edge in real time. This enables the graph to accurately associate the behavior-resource interaction patterns (such as memory leak risks) under the "ARMv8 architecture + Android 13 system" combination, completely solving the cross-platform misjudgment problem caused by the lack of platform information in traditional methods.
[0053] The behavior node is labeled with the operation type "payment click" and the duration (1.8 seconds), which are used as quantitative inputs in S200 risk identification: the operation frequency (1.8 seconds / time) is calculated based on the duration, and the impact range is assessed in combination with the type (payment operation triggers three types of resources: memory, CPU, and network, covering 60% of the total resources). Together with the risk probability (82%) and the platform risk coefficient (0.71), a priority score (1200×0.82×0.71=694.32) is generated, which improves the accuracy of risk probability calculation to 92% and avoids the one-sided assessment that relies only on frequency in traditional methods.
[0054] In this application embodiment, the process of calculating the platform risk coefficient using the dynamic attention mechanism, illustrated with case studies, specifically includes: In the payment operation case of an ARMv8+Android13 device, the mapping library, based on historical fault data, calculated that the platform combination had a memory leak failure rate of 85%, configuring a basic risk coefficient of 0.85 for a high-risk combination. The payment operation triggered three types of resources: memory, CPU, and network (accounting for 60% of the total resources), with a quantification factor of 0.6 and an initial risk coefficient of 0.51. After detecting the Android13 WebView interface vulnerability, a compensation value of +0.2 was added, resulting in a final risk coefficient of 0.71. This accurately distinguishes between platform risks that "have API vulnerabilities" and those that "have no vulnerabilities," avoiding the low-risk misjudgment caused by ignoring vulnerabilities in traditional methods.
[0055] The dynamic attention mechanism provides key inputs to the S300 priority scoring model (e.g., score = 1200 times per day × risk probability 82% × 0.71 = 694.32), ensuring that high-risk combinations (ARMv8 + Android13 payment operations) are prioritized for generating in-depth test cases, rather than being evenly distributed among test resources. This allows the edge-cloud testing of the S400 to focus on real high-risk scenarios, significantly improving testing efficiency.
[0056] By dynamically integrating historical fault data with real-time vulnerability verification, the accuracy of risk identification is increased to 92%, completely solving the problem of one-sided risk quantification under multi-platform combinations. This enables the overall solution to form a closed loop from S200 risk positioning to S500 platform expansion, realizing the transformation of compatibility testing from "passive response" to "proactive and precise prevention and control".
[0057] In the embodiments of this application, the method for constructing the ternary structure of the atom-parameter matrix-expected result is illustrated with examples, and further includes: In the ARMv8+Android13 payment operation case, the behavior pattern clustering algorithm accurately maps the high-frequency "continuous clicks on the payment button" behavior (duration 1.8 seconds, frequency 1200 times / day, memory surge of 100MB) to "payment operation atoms"; the parameter matrix, combined with the memory management features of the ARM architecture Bionic, dynamically sets the memory parameter range to 50-200MB (instead of a fixed value); the expected result is based on the historical memory leak root cause chain, combined with the Android13 compatibility score of 75, expanding the tolerance range from ±5% to ±15%, forming a high-precision ternary structure use case of "operation atom - parameter matrix - expected result".
[0058] The three-element structure of operation atom – parameter matrix – expected result provides precise input for S400 edge-cloud testing: The test environment built on the S400 cloud directly adopts dynamic parameter range (50-200MB) and dynamic tolerance (±15%) to ensure that test cases (such as "memory fluctuation of high-frequency payment operation ≤10%) are fully matched with the characteristics of the real platform, avoiding test deviations caused by static parameters in traditional methods (such as x86 architecture parameters being misused for ARM devices), and enabling S400 difference analysis (such as chi-square test p<0.05) to accurately locate the risk contribution node of "memory leak".
[0059] By adaptively generating the ternary structure of the atom-parameter matrix-expected result, the S300 transforms the risk probability (82%) and priority score (694.32) of the S200 into executable test cases, enabling the S400's test resources to focus 100% on high-risk scenarios (ARMv8 + Android13 payment operations), improving the efficiency of compatibility problem discovery by 40%, and achieving a test case accuracy of 92%, thus completely solving the problem of one-sided test case design under multi-platform combinations.
[0060] In this application embodiment, the preliminary verification mechanism for edge nodes is illustrated with examples, and the method further includes: In the payment operation case of an Android 13 device with an ARMv8 architecture, the TensorFlow Lite model deployed on the edge node (model size <8MB, inference latency <40ms) accurately identifies anomalies through a dynamic threshold mechanism: Based on the Bionic memory management features of ARMv8, the system uses an incremental algorithm (sliding window of 100 historical data) to calculate the standard deviation of memory fluctuation in real time (typical value of 12% for ARM platforms), dynamically expanding the threshold from the traditional fixed value of ±10% to ±15%. When the system detects that "continuous clicking of the payment button 5 times / minute" triggers a sudden increase in memory from 50MB to 150MB (an increase of 200%), 150MB far exceeds the dynamic threshold limit of 57.5MB (50MB × 1.15), and the system accurately marks it as a high-risk sequence. This avoids the traditional method from misjudging normal fluctuations on the ARM platform (such as natural memory fluctuations of ±12%) as anomalies due to a fixed threshold (±10%), reducing the false positive rate from 85% to 5%.
[0061] Through an incremental anomaly detection algorithm, edge nodes continuously optimize threshold parameters (such as updating the standard deviation of memory fluctuation every 5 minutes), uploading only 10 high-risk sequences (such as "continuous clicks + memory surge of 100MB") out of an average of 1200 payment operations per day to the cloud via the MQTT protocol. The lightweight nature of MQTT (single message <100 bytes) reduces the amount of uploaded data from 1200 to 10, reducing the communication load by 99.17% (i.e., 99%). The cloud test cluster directly receives anomaly characteristic data (including behavior ID, memory change, and platform identifier), skipping the repeated verification of low-risk operations and entering the deep testing environment of S400 step 2. The testing process is shortened from an average of 120 seconds to 40 seconds.
[0062] The initial verification mechanism improves the risk verification efficiency of ARMv8+Android13 devices by 3 times (120 seconds → 40 seconds), reduces communication load by 90%, and ensures that S400 testing resources are 100% focused on real high-risk scenarios (such as memory leaks in payment operations). Compared to the traditional method of full data transmission (1200 data entries) and the 85% false positive rate caused by platform-independent thresholds, this solution improves the speed of compatibility problem localization to the millisecond level (average response time <50ms), achieves a verification accuracy of 98%, and completely solves the problems of wasted testing resources and missed risk detection caused by data redundancy and threshold mismatch in multi-platform testing.
[0063] In this application embodiment, the method for identifying differences in resource consumption in a dynamic threshold screening system is illustrated with a case study, and further includes: In the ARMv8+Android13 payment operation case, the system used historical memory consumption data from 1000 payment operations over the past 30 days (mean 50.2MB, standard deviation 4.9MB) to construct a multidimensional distribution model using a Gaussian mixture model. The system dynamically calculated the memory fluctuation threshold to be 42.6-57.4MB (50.2±15%). Edge nodes detected a real-time surge in memory usage from 50.2MB to 150.5MB (a 199.8% increase) triggered by "5 consecutive clicks of the payment button per minute," far exceeding the dynamic threshold of 57.4MB. The system accurately flagged this as a high-risk sequence, avoiding the misjudgment of normal fluctuations in ARM architecture Bionic memory management (such as natural fluctuations of ±10%) as abnormal using traditional fixed thresholds (e.g., ±10%). The false positive rate plummeted from 85% to 3%.
[0064] In the cloud-based test environment simulating payment operations, the average memory consumption was 55.1MB (standard deviation 2.8MB), while the average memory consumption of edge-reported anomalies was 150.5MB. Chi-square tests precisely calculated and generated "memory consumption anomaly" analysis results. These results directly drove the deep testing in step 2 of the S400, validating only high-risk sequences of 10 payment operations per day (an average of 1200 operations), avoiding redundant processing of the 1190 low-risk operations, thus improving testing efficiency by 3 times.
[0065] The backpropagation algorithm combines the node relationships in the heterogeneous graph of "payment operation → memory consumption → ARMv8 architecture" (with a memory consumption node weight of 0.75) and the platform risk coefficient of 0.71 to calculate the contribution of the ARMv8 architecture to memory leaks as 0.75 × 0.71 = 0.5325, generating a complete risk root cause chain of "payment operation → memory leak → ARMv8 memory management defect". This mechanism enables compatibility issues to be accurately identified with an accuracy rate of 98%, and reduces the risk location speed from the traditional minutes to 45ms (milliseconds), completely solving the problems of "threshold mismatch + misjudgment + root cause ambiguity", ensuring that the S500 remediation strategy is 100% focused on the Bionic memory management defect of the ARMv8 architecture, improving remediation efficiency by 40%.
[0066] This application discloses a multi-platform compatibility automated testing system, referring to... Figure 2 ,include: The causal graph construction module 001 acquires multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test equipment underlying platform feature data. It establishes causal relationships among the three types of data through a time-series alignment algorithm, generating a three-dimensional heterogeneous correlation graph containing four types of correlation edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information. The dynamic risk identification and probability prediction module 002 identifies risks based on a three-dimensional heterogeneous association graph by integrating a dynamic attention mechanism and an enhanced graph neural network with temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform node and assigns dynamic weights to the nodes in combination with the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operators, the high-risk behavior sequence and the corresponding risk probability are output. The test case adaptive generation module 003 constructs a test case gene library with a three-element structure of operation atom-parameter matrix-expected result based on high-risk behavior sequences, obtains the user behavior frequency corresponding to the user, adaptively adjusts the test parameters based on the underlying feature data of the platform node, and constructs a priority scoring model by combining user behavior frequency and risk probability to generate deep compatibility test cases. The edge-cloud collaborative shadow testing module 004 deploys an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. The module verifies functional consistency by comparing the feature values of the output results, obtains corresponding difference analysis results by screening differences in system resource consumption based on dynamic thresholds, associates heterogeneous graph node relationships and attention weights, traces risk-contributing nodes in reverse, and generates a complete risk root cause chain of behavior-resource-platform. The platform adaptive model update module 005 adopts a modular structure of a backbone graph neural network and a platform adaptation branch. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the newly added platform test data. The newly added platform test data includes running logs, system resource consumption data, and output results. Historical key risk samples are retained through a memory replay mechanism, and adaptive identification of new platform compatibility risks is achieved through dynamic threshold adjustment based on the new platform data and difference analysis results.
[0067] This application also discloses a multi-platform compatibility automated testing system, including a processor, wherein the processor runs a program of any one of the multi-platform compatibility automated testing methods described above.
[0068] This application also discloses a storage medium storing a program for the multi-platform compatibility automated testing method described in any one of the above embodiments.
[0069] Although embodiments of this application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting this application. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of this application.
Claims
1. A multi-platform compatibility automated testing method, characterized in that, include: Acquire multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test equipment underlying platform feature data. Establish causal relationships among the three types of data through a time-series alignment algorithm, and generate a three-dimensional heterogeneous association graph containing four types of association edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information. Risk identification is performed based on the aforementioned three-dimensional heterogeneous correlation graph by fusing dynamic attention mechanism and temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform node, and assigns dynamic weights to the nodes in combination with the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operator, the high-risk behavior sequence and the corresponding risk probability are output. Based on the high-risk behavior sequence, a test case gene library with an operation atom-parameter matrix-expected result ternary structure is constructed to obtain the user behavior frequency corresponding to the user. Based on the underlying feature data of the platform node, the test parameters are adaptively adjusted. A priority scoring model is constructed by combining the user behavior frequency and the risk probability to generate deep compatibility test cases. Deploy an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. Functional consistency is verified by comparing the feature values of the output results. Differences in system resource consumption are screened based on dynamic thresholds to obtain corresponding difference analysis results. The relationships between heterogeneous graph nodes and attention weights are correlated, risk-contributing nodes are traced in reverse, and a complete risk root cause chain of behavior-resource-platform is generated. A modular structure of backbone graph neural network + platform adaptation branch is adopted. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the test data of the new platform. The test data of the new platform includes operation logs, system resource consumption data and output results. Historical key risk samples are retained through memory replay mechanism. Based on the data of the new platform and the difference analysis results, the compatibility risk of the new platform is adaptively identified by adjusting the dynamic threshold.
2. The multi-platform compatibility automated testing method according to claim 1, characterized in that, In establishing causal relationships among three types of data using time-series alignment algorithms, the method also includes: Set the duration of the sliding time window, and perform time slicing on user behavior sequence data and system resource interaction data based on the sliding time window; calculate the mutual information entropy of behavior operations and resource consumption within the same time window, set the corresponding mutual information entropy filtering threshold, and select strongly correlated data pairs based on the mutual information entropy filtering threshold; Static attribute annotation is performed on the underlying platform feature data, which includes hardware architecture model and OS kernel version. The annotated underlying platform feature data is bound to strongly correlated data pairs through timestamp mapping to generate a three-dimensional heterogeneous correlation map. Attribute annotation is performed on nodes in a 3D heterogeneous correlation graph, specifying the operation type and duration for behavior node annotation.
3. The multi-platform compatibility automated testing method according to claim 1, characterized in that, In the process of calculating the risk coefficient of the dynamic attention mechanism platform, the method also includes: Construct a mapping library corresponding to hardware architecture, operating system, and historical failures. Based on the mapping library, calculate the compatibility failure rate under each hardware architecture and operating system combination. Divide the combination into high-risk and low-risk combinations according to the compatibility failure rate, and configure a higher basic risk coefficient for high-risk combinations than for low-risk combinations. The quantitative factor corresponding to the scope of influence of the behavior is calculated. The quantitative factor is determined based on the ratio of the number of resource nodes triggered by the behavior node to the total number of resource nodes. The quantitative factor changes positively with the increase or decrease of the ratio of the number of triggered resource nodes. The initial platform risk coefficient is calculated by multiplying the basic risk coefficient and the quantitative factor of the scope of influence of the behavior. When a platform node OSAPI has a version compatibility vulnerability, and the authenticity of the version compatibility vulnerability is confirmed by matching and verification through the vulnerability database, a preset risk compensation value is added to the initial platform risk coefficient. The value of the preset risk compensation value must ensure that the added value can effectively distinguish the platform risk difference between platforms with API version compatibility vulnerabilities and those without version compatibility vulnerabilities, and finally obtain the corresponding platform risk coefficient.
4. The multi-platform compatibility automated testing method according to claim 3, characterized in that, In the process of constructing the ternary structure of the atom-parameter matrix-expected result, the method also includes: A clustering algorithm based on behavioral patterns maps high-frequency user behavior sequences into sets of operation atoms. The clustering algorithm performs clustering based on the duration of user behavior, operation frequency, and resource consumption patterns. The generation of the parameter matrix is combined with the system resource consumption sensitivity analysis, and a dynamic parameter range is set for memory-sensitive operations. The dynamic parameter range is adaptively adjusted based on the underlying feature data of the platform node. The expected results are generated using behavior-resource joint constraint modeling. The modeling process includes: extracting key constraints based on historical risk root cause chains, and dynamically adjusting the tolerance range of the expected results in conjunction with the compatibility scores of platform nodes.
5. The multi-platform compatibility automated testing method according to claim 4, characterized in that, The initial verification mechanism for edge nodes also includes the following methods: Deploy a lightweight inference model to perform real-time feature extraction on replicated user requests. Real-time feature extraction includes pattern recognition of behavioral sequences and anomaly detection of resource consumption. An incremental anomaly detection algorithm is used to identify sudden changes in resource consumption at the edge. The incremental anomaly detection algorithm dynamically updates the anomaly threshold to adapt to the resource fluctuation characteristics under different platform architectures. The initial verification results are uploaded to the cloud test cluster via the MQTT protocol. The edge nodes only upload the verification data of high-risk behavior sequences to reduce the communication load between the edge and the cloud.
6. The multi-platform compatibility automated testing method according to claim 5, characterized in that, In the process of differentiating resource consumption in a dynamic threshold screening system, the method also includes: A multidimensional distribution model is constructed based on historical resource consumption data to dynamically calculate the normal range threshold of resource consumption. By comparing the resource consumption data of the cloud testing environment and the preliminary edge verification, the chi-square test is used to determine the significance of the differences, and the difference analysis results are generated based on the significance level. By associating heterogeneous graph node relationships and attention weights, risk-contributing nodes are tracked through a backpropagation algorithm. The backpropagation algorithm combines the platform risk coefficient and the behavioral impact range quantification factor to generate a complete risk root cause chain of behavior-resource-platform.
7. A multi-platform compatibility automated testing system, characterized in that, include: The causal graph construction module acquires multi-dimensional basic data, including user behavior sequence data, application runtime system resource interaction data, and test equipment underlying platform feature data. It establishes causal relationships among the three types of data through a time-series alignment algorithm, generating a three-dimensional heterogeneous correlation graph containing four types of correlation edges: behavior nodes, resource nodes, platform nodes, trigger edges, dependency edges, time-series edges, and compatibility edges. Each node carries corresponding dimensional attribute information. The dynamic risk identification and probability prediction module identifies risks based on the three-dimensional heterogeneous correlation graph by integrating a dynamic attention mechanism and an enhanced graph neural network with temporal graph convolution. The dynamic attention mechanism calculates the corresponding platform risk coefficient based on the hardware architecture-operating system combination features of the platform node and assigns dynamic weights to the nodes in combination with the behavioral influence range of the behavioral nodes. The temporal graph convolution aggregates the node features of different time window subgraphs in the heterogeneous graph through 1D-CNN. After cross-type node feature interaction is achieved through graph convolution operators, the module outputs high-risk behavior sequences and corresponding risk probabilities. The test case adaptive generation module constructs a test case gene library with an operation atom-parameter matrix-expected result ternary structure based on the high-risk behavior sequence, obtains the user behavior frequency corresponding to the user, adaptively adjusts the test parameters based on the underlying feature data of the platform node, and constructs a priority scoring model by combining the user behavior frequency and the risk probability to generate deep compatibility test cases. The edge-cloud collaborative shadow testing module deploys an edge-cloud collaborative shadow testing architecture. Edge nodes replicate user requests corresponding to high-risk behavior sequences in milliseconds and perform preliminary local verification. The cloud constructs a test environment matrix based on the underlying feature data of platform nodes, receives verification data, and executes deep compatibility test cases in parallel. It also collects runtime logs, system resource consumption data, and output results synchronously. The module verifies functional consistency by comparing the feature values of the output results, obtains corresponding difference analysis results by screening differences in system resource consumption based on dynamic thresholds, associates heterogeneous graph node relationships and attention weights, traces risk-contributing nodes in reverse, and generates a complete risk root cause chain of behavior-resource-platform. The platform adaptive model update module adopts a modular structure of backbone graph neural network + platform adaptation branch. The backbone network is based on the general feature learning results of the enhanced graph neural network, and the platform adaptation branch performs parameter fine-tuning on the newly added platform test data. The newly added platform test data includes operation logs, system resource consumption data and output results. Historical key risk samples are retained through memory replay mechanism, and adaptive identification of new platform compatibility risks is achieved through dynamic threshold adjustment based on the new platform data and difference analysis results.
8. A multi-platform compatibility automated testing system, characterized in that, Includes a processor, wherein the processor runs a program of the multi-platform compatibility automated testing method as described in any one of claims 1-6.
9. A storage medium, characterized in that, A program storing the multi-platform compatibility automated testing method as described in any one of claims 1-6.
Citation Information
Cited By
API risk detection method and device and storage medium
CN121547297A
