Next Article in Journal
Depth Estimation from a Hierarchical Baseline Stereo with a Developed Light Field Camera
Previous Article in Journal
CWD-Sim: Real-Time Simulation on Grass Swaying with Controllable Wind Dynamics
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

An Effective GDP-LSTM and SDQL-Based Finite State Testing of GUI

1
Department of Computer Science and Engineering, Veer Madho Singh Bhandari Uttarakhand Technical University, Dehradun 248007, India
2
Department of Electrical Engineering and Computer Science, University of Cincinnati, Cincinnati, OH 45221, USA
3
Department of Computer Science and Engineering, Dev Bhoomi Institute of Technology, Dehradun 248007, India
*
Author to whom correspondence should be addressed.
Appl. Sci. 2024, 14(2), 549; https://doi.org/10.3390/app14020549
Submission received: 7 December 2023 / Revised: 2 January 2024 / Accepted: 5 January 2024 / Published: 8 January 2024
(This article belongs to the Section Computing and Artificial Intelligence)

Abstract

:
The Graphical User Interface (GUI) is the most promising factor in the Software Development Lifecycle (SDL), which allows the users to interact with the system. To ensure user-friendliness, GUI Testing (GT) is required. The traditional testing techniques attained flawed results due to having inappropriate functions. Hence, Global Decaying Probabilistic Long Short-Term Memory (GDP-LSTM) and Standard Deviation Q-Learning (SDQL)-based automatic testing for GUI are proposed as solutions. Initially, the Test Case (TC) and GUI are extracted from the historical data and are subjected to Region of Interest (ROI) analysis. Here, an appropriate ROI is analyzed by Module Coupling Slice (MCS), and it is fed into Hadoop Parallelization (HP). Now, Spectral Kernelized Gaussian Clustering (SKGC) and Non-Linear Elite Guided Optimized Ant Colony (NE-GO-AC) are used to perform mapping and reducing, respectively. Likewise, the parallelized output is utilized to construct the Document Object Model (DOM) tree. Then, the attributes are extracted and given to the GDP-LSTM classifier that effectively predicts whether GUIs are desirable or undesirable. Then, the undesirable results are inputted into a SDQL-based deviation analysis. If the deviation is low, it is assumed as an update; otherwise, it is considered as an error. The experimental analysis depicted that the proposed system attained high dominance with 98.89% accuracy in the prevailing models.

1. Introduction

In SDL, the GUI plays a leading role that ensures the effective interaction between users and the system via graphical icons [1,2]. Recently, the necessity for GUI has rapidly grown due to its high availability in users’ daily routines [3]. Hence, GT is required to guarantee user satisfaction [4]. In traditional models, manual testing of GUI is carried out, thus resulting in time consumption and leading to inconsistent results [5]. Therefore, automatic GT tools have evolved to confirm the system’s dependability [6].
In existing techniques, the GT tools are integrated with different Machine Learning (ML) and Deep Learning (DL) approaches to achieve GT based on TC generation [7,8]. The ML and DL models, including the Fuzzy Inference System (FIS), Long Short Term Memory (LSTM), and Deep Reinforcement Learning (DRL) are developed to perform GT [9]. However, these techniques struggle with complex features and samples [10]. Therefore, GDP-LSTM and SDQL-based automatic finite state testing of GUI is proposed.

1.1. Problem Statement

  • None of the previous models focused on TC update requests that prompt incorrect results.
  • The style characteristics of the GUI are considered as noise, which degrades the testing process.
  • The existing techniques attained high time complexity due to the multiple GUI.
  • The conventional methods struggle with the complex features of the GUI.
  • The selection of appropriate ROI in GT is still difficult.

1.2. Objectives

  • The GDP-LSTM and SDQL are established to distinguish the update and error of the GUI.
  • An efficient MCS analysis is conducted to identify the suitable ROI.
  • HP is carried out to handle the multiple GUI along with style characteristics.
  • The DOM tree analysis deals with complex structures.
  • The paper’s structure is as follows: Section 2 deliberates the literature review; Section 3 derives the proposed framework; Section 4 illustrates the performance analysis; and Section 5 concludes the article.

2. Related Literature Survey

Pan et al. [11] developed a framework named GUI-guided test script repair for mobile applications. Here, an effective meter scheme was employed for the repair of bugs and faults in the GUI test scripts. The developed model comprised key processes like GUI matching, GUI element extraction, and screen matching. The analysis outcomes stated that the developed model achieved effective performance in GUI testing; however, the developed model took more training time to achieve significant GUI test results.
Yan et al. [12] presented the testing approach for GUI applications based on event sequence reduction. The monkey testing tool was integrated with an event sequence reduction, which was utilized to perform GT. The system effectively eradicated the crash of irrelevant events in GUI, but it required a massive amount of sequences for system implementation.
Pastor Ricós et al. [13] demonstrated the capability of scriptless GT by using distributed state model inference. Here, the Testar testing tool was employed to validate the GUI based on the distributed model, which contained numerous distributed instances. This model achieved low time complexity during GT. However, it attained high installation costs.
Kumar et al. [14] established the test case prioritization based on finite state GT. Here, techniques, such as the ZScore-Bald Eagle Search (Z-BES) and Gini Kernel-Gated recurrent unit (GK-GRU) were introduced to perform the test case prioritization and GT, respectively. This technique outperformed with an accuracy of 98%; however, it retained false positives due to its lack of sufficient attributes.
Kumar et al. [15] developed the finite state testing of GUI applications using genetic algorithms. Here, a genetic algorithm was introduced to generate the test cases. Then, it was subjected to construct the state transition diagram. A state diagram was encoded to evaluate the GUI. This system acquired better performance in test case generation; however, this technique acquired unsatisfactory results.
Ardito et al. [16] developed an automated test selection for Android applications based on activity classification. The framework consisted of a test scripting language, State graph modeler, application classifier, activity classifier, and test adapter for automatic GUI testing. The developed model was effectively adapted to high-level test cases. However, the developed model was an insignificant model which cannot provide an effective defect-finding power.
Koroglu and Sen [17] presented a fully automated reinforcement learning-driven specification-based test generator for an Android application. The developed model transferred the user interface test scenarios to GUI-level specifications using the linear-time temporal logic formula. The analysis proved that the developed framework was more effective and attained high performance in the test generations. However, the developed model failed to test many essential GUI functions, which led to inefficient test generation.
Coppola et al. [18] incorporated the scripted GT for Android applications based on test code generation. The features were extracted from the collected GitHub repository [19]. Then, it was subjected to test code generation based on grounded theory. This model was effective in detecting bugs in GUI. However, it was not applicable for closed-source developments.

3. Proposed Methodology

In the proposed architecture, an automatic finite state testing of GUI is implemented by using GDP-LSTM and SDQL. The proposed model’s structure is depicted in Figure 1.

3.1. Test Case and GUI Extraction

The historical project data H v Δ are gathered, and then the test case T n and GUI q are extracted separately from H v Δ . This is represented as,
H v Δ H 1 Δ , H 2 Δ , H V Δ   Here ,   v = 1 , 2 , V
T n ° = T 1 ° , T 2 ° T N °
q 1 , 2 , Q   Where ,   q = 1   t o   Q
where v symbolizes the number of H v Δ , n = 1 , 2 , N , and Q indicates the total number of extracted T n and q , respectively.

3.2. ROI Selection

The ROI is considered as a sample of data from the TCs and GUI. Next, by using the MCS, a suitable ROI is selected by considering the priority of T n and q . The MCS is a technique that uses a module-coupling value for the detection of critical modules in the software. Initially, the module coupling matrix C o p m a t is generated for T n and q as,
C o p m a t =   x u T 1 , 1 x u T n , q x u T N , Q 1 × n , q
where u = 1   t o   U denotes the number of coupling values ( x u ). Similarly, the module cohesion matrix C o h m x is constructed based on the cohesion type e c o h and its equivalent value l w .
C o h m x e , w = 1 E , W e c o h + l w T 1 , 1 e c o h + l w T n , q e c o h + l w T N , Q 1 × n , q
where w and e indicate the number of equivalent values and the cohesion type, respectively. Finally, C o p m a t and C o h m x are utilized to create the module dependency matrix D e p Θ as,
D e p Θ = 0.7 C o p m a t x u + C o h m x × 0.15
Here, the optimal ROI Ξ is identified by considering the highest value in D e p Θ .
Ξ b e s t max D e p Θ
λ o = Ξ T n + q
where o = 1 , 2 , O indicates the number of ROI analyzed data λ o .

3.3. Hadoop Parallelization

Similarly, λ o is subjected to perform HP that includes mapping and reducing to handle the multiple GUI, which is elaborated through the following.
Mapping: Mapping helps to visually demonstrate the requirements for the software acceptance. The mapping is conducted for λ o by using SKGC. The Spectral Clustering (SC) is chosen due to its better scalability in high-dimensional data. However, the random epsilon values affect the clustering outcomes in SC. Due to this, the proposed work employs the Gaussian Kernel (GK) mapping function to choose the epsilon values, which helps to attain effective clustering. The GK is utilized for its ability to attain effective clustering through lower dimensional space, which is then derived further.
The similarity graph of the Data Points (DP) is primarily constructed in the form of an affinity matrix A . Here, the epsilon value e p s selection and similarity measure are performed by using the GK mapping function χ .
χ λ o exp λ 1 λ 2 2 2 ρ 2 , ρ > 0
= o = 1 O 2 1 χ λ o e p s
A e p s
where ρ indicates the GK parameter. The DP in the affinity matrix is connected to the points, which fall in the radius of e p s . Then, the Laplacian matrix l Ψ is created by using A and diagonal matrix d . This is defined by,
l ψ = d A
Likewise, the Eigenvalues and Eigenvectors r e i g are decomposed from l ψ . Here, l ψ is written in the linear form for some scalar values W e i g , and then W e i g is assumed as an Eigenvalue.
l ψ r e i g = W e i g × r e i g
Then the r e i g , with respect to minimum non-zero W e i g , are utilized to map the DP into lower-dimensional space. Thus, the K number of transformed data T k is depicted as,
T k = T 1 , T 2 , T K   Here ,   k 1 , 2 , K
Finally, T k is subjected to the clustering process by using the k-means algorithm. Here, the number of clusters ν is assumed; then the centroid point σ c e n is randomly selected from T k . Subsequently, the distance ϕ d i s among T k and σ c e n is estimated. Then the DP is assigned to the nearest cluster. This is formulated as,
ϕ d i s = k = 1 K T k σ c e n 2
min ϕ d i s ν T k
Thus, the B number of mapped data E is represented as,
E = b = 1 B E 1 , E b , E B
Reducing: Afterwards, the mapped data E are reduced by using NE-GO-AC. Ant Colony Optimization (ACO) is established because ACO provides rapid detection of optimal solutions. The ACO is a metaheuristic algorithm based on the foraging behavior of the ants in finding the shortest path to their food sources. The parameters of the proposed NE-GO-AC are as follows: ants’ population I a , non-linear transition parameter τ l i n , pheromone concentration η E 1 , b , fitness F i t Φ , time-bounds U , heuristic information φ E 1 , b , and volatilization factor ϑ . Nevertheless, it attained a local optimum solution due to a low convergence rate. Therefore, the proposed work incorporates the elite guidance-based searching process and non-linear transition parameters to optimize the convergence rate. The proposed Algorithm 1 NE-GO-AC is discussed below.
Here, the E is considered as the ant, and it is initialized as follows,
I a = E 1 , 1 E 1 , b E 1 , B 1 × B
where I a indicates the population matrix. Subsequently, the Fitness Value F i t Φ is estimated by considering the maximum similarity, which is expressed as,
F i t Φ I a = max F i t Φ E 1 , 1 F i t Φ E 1 , b F i t Φ E 1 , B 1 × B
Likewise, the searching process of the ant is completed by releasing the pheromone ζ n and constantly updating its position by changing ζ n , which is initialized by using a non-linear transition parameter τ l i n ,
ζ n = τ l i n ζ n , ζ n , ζ n   Here ,   n = 1   t o   N
τ l i n x 1 sin 1 u U π 0.5 + x 2
where N signifies the number of ζ n , u and U indicate the time-bounds, and x 1 and x 2 represent the constant parameters, respectively. Then, the probability p r o E 1 , b is estimated by,
p r o E 1 , b i = η E 1 , b i n × φ E 1 , b i n b = 1 B η E 1 , b i n × φ E 1 , b i n
where η E 1 , b denotes the pheromone concentration, φ E 1 , b indicates the heuristic information, and i specifies the time frame. Then, the best fitness value and high probability are used to select the best candidate solution β E 1 , b ,
β E 1 , b max p r o E 1 , b , b e s t F i t Φ I a
The search process is continued by following the β E 1 , b . Then, the pheromone concentration of the individual ant is updated by using an elite search and is given as,
η E 1 , b i + 1 1 ϑ I a τ l i n sin 2 π   r n d I a τ l i n cos 2 π   r n d + 2   r n d   I a η E 1 , b i 2   r n d   I a η E 1 , b i + Ζ η E 1 , b i , ϑ 0 , 1
where ϑ indicates the volatilization factor, η E 1 , b i + 1 denotes the updated η E 1 , b , r n d indicates the random value, and Ζ η E 1 , b i represents the sum of the η E 1 , b of each ant. The F number of reduced data ƛ f is represented as,
ƛ f = ƛ 1 , ƛ 2 , ƛ F   where ,   f = 1   t o   F
Algorithm 1: NE-GO-AC
Input: Mapped data E
Output: Reduced data ƛ f
Begin
Initialize population matrix I a , fitness F i t Φ , β E 1 , b , τ l i n , ϑ ,   η E 1 , b , φ E 1 , b , U and ζ n
For each ant E 1 , b  do
  Initialize population
  Compute fitness function F i t Φ  
  Update position, ζ n = τ l i n ζ n , ζ n , ζ n  
  Estimate non-linear transition parameter,
     τ l i n x 1 sin 1 u U π 0.5 + x 2  
  Measure probability, p r o E 1 , b i = η E 1 , b i n × φ E 1 , b i n b = 1 B η E 1 , b i n × φ E 1 , b i n  
    Select best candidate solution β E 1 , b  
  Implement  η E 1 , b i + 1
End for
Return reduced data ƛ f
End
The pseudo-code for NE-GO-AC is demonstrated above.

3.4. DOM Tree Construction

Next, the ƛ f is applied to construct the DOM tree m ο . The analysis of the DOM tree is used to represent the document in a hierarchical form that helps to handle complex features, such as maps, flowcharts, and diagrams. The DOM tree structure is generated with the root nodes and the child nodes. In the DOM tree structure, the class is assumed as root node regarding high priority, and further components are child nodes that are structured with respect to high priority to low priority order. Here, ƛ f is separated as a class μ y c l s , sub-class α c s u b , function δ d f u n , and sub-functions υ j s f n , which are constructed as,
μ y c l s ƛ f m ο α 1 s u b ƛ f α c s u b ƛ f α C s u b ƛ f δ 1 f u n ƛ f δ d f u n ƛ f δ D f u n ƛ f υ 1 s f n ƛ f υ j s f n ƛ f υ J s f n ƛ f
Here, y = 1   t o   Y , c = 1   t o   C , d = 1   t o   D , and j = 1   t o   J indicate the number of μ y c l s , α c s u b , δ d f u n , and υ j s f n , respectively.

3.5. Attributes Extraction

Then, the attributes, such as type, ID, color, fonts, graphics, and size are extracted m ο to improve the classification performance (Silistre et al., 2020), which is defined as,
ξ h Δ = ξ 1 Δ , ξ 2 Δ ξ H Δ   Here ,   h = 1 , 2 , H
where H indicates the number of extracted attributes ξ h Δ .

3.6. GUI Testing

The GUI consists of several visual elements like buttons, text boxes, menus, checkboxes, and images. The GUI testing validates the features of an application to ensure that it meets the requirements. Likewise, ξ h Δ is subjected to a GDP-LSTM to achieve GT. The LSTM has three diverse gates, including forget gate, input gate, and output gate, and it is employed because of having long-term dependencies. However, it attained poor learning efficiency due to the huge amount of parameters. Hence, the proposed work incorporates the Global Decayed Learning Rate and Probabilistic Activation Function (PAF) to enhance the learning capacity. The architecture of GDP-LSTM is shown in Figure 2.
The proposed work employs the PAF r o Ξ to upgrade the learning process of the neurons. The PAF is defined as,
r o Ξ κ ε ξ h Δ + B Ω r a n d
Here, κ ε denotes the static mean, B Ω indicates the perturbation parameter, and r a n d represents the random value, which falls between [0, 1].
Forget Gate: The forget gate f g t ι eradicates irrelevant information. Here, the inputs like ξ h Δ and H i d o 1 , which represent the input from the present state and previous hidden state, respectively, are considered to perform f g t ι . This is formulated by,
f g t t = r o Ξ w t H i d o 1 , ξ h Δ + β i δ
Here, w t and β i δ specify the weight and bias, respectively.
Input gate: The input gate i p t permits the essential information to pass through the gates. This is written as,
i p t = r o Ξ × w t × H i d o 1 , ξ h Δ + β i δ
ϕ w c e l l = T a n h w t H i d o 1 , ξ h Δ + β i δ
ϕ w c e l l = f g t ι ϕ w 1 c e l l , i p t ϕ w c e l l
where ϕ w c e l l represents the present cell state, ϕ w c e l l denotes the vector function of the cell state, depicts the element-wise multiplication, T a n h specifies the tangent function, f g t ι ϕ w 1 c e l l represents the removed information, and i p t ϕ w c e l l indicates the allowed information.
Output gate: In the output gate o p t , the important information from ϕ w c e l l is recognized, and then the relevant information is presented as an outcome, which is shown as,
o p t = r o Ξ w t 1 H i d o 1 , ξ h Δ + β i δ
Here, the proposed GDP-LSTM introduces the global decayed learning rate K α glb to improve the model efficiency by,
w t 1 K α glb s l + ν c o n w t
H i d o = o p t T a n h ϕ w c e l l
where w t 1 indicates the updated weight, s l and ν c o n represent the scale factor and stability constant, respectively, and H i d o denotes the result of the present hidden state. Finally, the proposed Algorithm 2-GDP-LSTM predicts whether the GT is desirable χ d e s or undesirable δ u n d e s . The outcome O Λ l s t m of the GDP-LSTM is presented as,
O Λ l s t m χ d e s , δ u n d e s
Algorithm 2: GDP-LSTM
Input:   Extracted   attributes   ξ h Δ
Output:   GUI   testing   results   O Λ l s t m
Begin 
  Initialize  r o Ξ , f g t ι , χ d e s , δ u n d e s and K α glb  
  For 1 to H of attributes
    Evaluate PAF r o Ξ κ ε ξ h Δ + B Ω r a n d  
    Perform  f g t t = r o Ξ w t H i d o 1 , ξ h Δ + β i δ  
    Execute  i p t = r o Ξ × w t × H i d o 1 , ξ h Δ + β i δ  
    Compute  o p t = r o Ξ w t 1 H i d o 1 , ξ h Δ + β i δ  
  End For 
  Return  O Λ l s t m χ d e s , δ u n d e s
End
The pseudocode for GDP-LSTM is depicted above. The δ u n d e s is subjected to perform the following process that will categorize the update and error of the testing results.

3.7. Deviation Analysis

The deviation analysis is performed for the attributes between sample update requests s p l π , q , and ξ h Δ by using the SDQL technique. The traditional Q-Learning is introduced due to its high learning capability. The proposed work establishes the Standard Deviation Empirical Rule (SDER) based on Q-learning. This is discussed as follows.
Initially, the s = 1   t o   S number of attributes between s p l π and q is defined as φ s a t t . Here, the deviation score s t d θ between φ s a t t and ξ h Δ is measured as,
s t d θ φ s a t t , ξ h Δ m n s n λ
where m n and s n λ indicate the mean and standard deviation of φ s a t t and ξ h Δ . Then, the SDER r u l e s is applied as,
r u l e s = i f s t d θ 68 % , l o w s n λ m n i f s t d θ 95 % , m e d i u m s n λ m n i f s t d θ 99.7 % , h i g h s n λ m n
Q l s t e v , a c t v r u l e s 1 l r Q l s t e v , a c t v + l r r e w v + 1 + d i s f max a c t v + 1 Q l s t e v + 1 , a c t v + 1
where Q l represents the Q-value; s t e v and a c t v indicate the current state and action, respectively; l r denotes the learning coefficient; r e w v + 1 specifies the reward; d i s f represents the discount factor; and s t e v + 1 and a c t v + 1 denote the next state and action, respectively.
If the s t d θ is around 68%, then it is assumed as r e w v + 1 . Likewise, if the s t d θ is around 95% to 99.7%, then it is assumed as a c t v . Here, r e w v + 1 is referred to as an update and a c t v is referred to as an error of the GT.

4. Results and Discussion

The proposed model’s performance is assessed here by analogizing it to existing models, and it is implemented on the working platform of PYTHON.

4.1. Dataset Description

The proposed system is implemented by using “Dataset-for-GUI-Components” (DGC), which contains information about image files, class numbers, and data labels of GUI. The dataset holds 726 labeled data. From these, 80% of the data are allocated for training and 20% of the data are used for testing.

4.2. Performance Evaluation

Here, the performance analysis of the proposed framework is executed to prove the model’s supremacy. The activity coverage analysis of the proposed SDQL is presented in Table 1.
Table 1 demonstrates the evaluation of the proposed SDQL and existing techniques like QL, Reinforcement Learning (RL), State-Action-Reward-State-Action (SARSA), and Temporal Difference Learning (TDL) regarding Activity Coverage (AC). The proposed SDQL employs the SDER to categorize the update or error that improves the model performance. The proposed SDQL achieved an AC of 91.83%, whereas traditional works retained a limited AC of 82.14%. The proposed SDQL outperformed the conventional models. Then, the performance analysis of the proposed SDQL centered on Mean Squared Error (MSE) and Mean Absolute Percentage Error (MAPE) is graphically represented in Figure 3a,b.
Based on MSE and MAPE, the performance validation of the proposed work and existing techniques is shown in Figure 3. The proposed SDQL obtained an MSE and MAPE of 1.018% and 0.305%, respectively. Furthermore, the traditional models acquired an average MSE and MAPE of 6.173% and 0.675%, respectively. The proposed system is proved as a less error-prone model. Next, the proposed SDQL’s Processing Time (PT) is analyzed with the existing works in Figure 4.
Figure 4 compares the PT of the proposed SDQL and conventional models. The proposed SDQL takes a minimum PT of 21,456 ms. However, existing systems attained the PT in approximately 36,470 ms. From Figure 4, it is clear that the proposed framework achieved low time complexity. Similarly, the Test Case Length (TCL) vs. Correctly Classified (CC) analysis of the proposed SDQL is described in Figure 5.
Figure 5 validates the proposed SDQL regarding Test Case Length (TCL) vs. CC. The proposed SDQL obtained a CC of 92.45% when the TCL is 20. Likewise, the traditional algorithms retained an average CC of 88.26% when the TCL is 20. The analysis results justified that the proposed model has better superiority than the prevailing works. The effectiveness of the proposed GDP-LSTM is proved and centered on in the analysis of performance metrics in Figure 6a,b.
The above figures illustrate the performance analysis of the GDP-LSTM. Figure 6 compares the proposed GDP-LSTM and existing classifiers like LSTM, GRU, Bidirectional LSTM (Bi-LSTM), and Recurrent Neural Network (RNN). The proposed GDP-LSTM introduces the global decayed learning rate and PAF to enhance the classification results of GT. The proposed GDP-LSTM achieved an accuracy, precision, F-measure, sensitivity, specificity, and recall of 98.89%, 98.98%, 99.21%, 98.97%, 98.84%, and 98.77%, respectively. The proposed GDP-LSTM retained FPR and FNR of 5.933% and 6.167%, respectively. Furthermore, the existing models reached an average accuracy, precision, F-measure, sensitivity, specificity, and recall of 94.63%, 95.05%, 94.29%, 94.04%, 95.14%, and 94.26%, respectively. The traditional models obtained an FPR and FNR of 8.651% and 9.099%, respectively. Figure 6 depicts the proposed model’s reliability. In Table 2, the clustering time analysis of the proposed SKGC and the existing works are stated.
The Clustering Time (CT) evaluation of the proposed SKGC and prevailing approaches is presented in Table 2. The proposed SKGC incorporates the GK mapping function to attain effective clustering. The proposed SKGC takes a minimum time of 56,942 ms to perform clustering. However, the conventional algorithm obtained an average CT of 91,586 ms. Hence, the proposed work retained better performance in data mapping. The performance analysis of the proposed NE-GO-AC and the existing models are represented in the following Figure 7.
In Figure 7, the proposed NE-GO-AC is compared to traditional techniques like ACO, Whale Optimization Algorithm (WOA), Particle Swarm Optimization (PSO), as well as Genetic Algorithm (GA). The proposed work establishes elite guidance, along with non-linear transition parameters to optimize the convergence rate. The proposed NE-GO-AC attained a Normalized Fitness Function (NFF) of 584, whereas the traditional algorithms reached an average NFF of 1319. The proposed NE-GO-AC acquired optimal results in the reducing process.

4.3. Comparative Analysis

Here, the proposed system’s performance is validated by analogizing it to related works, which are described in Table 3.
Table 3 analyzes the proposed work’s performance by comparing it to related models. The proposed GDP-LSTM utilizes the global decayed PAF to achieve efficient GT. Likewise, SDQL established SDER to identify the update or error of the testing results that enhance the GUI performance. Similarly, the existing models introduce techniques like You Only Look Once (YOLO), RL, and LSTM. The proposed model achieved PT, precision, accuracy, F-measure, and CC of 21,456 ms, 98.98%, 98.89%, 99.21%, and 92.45%, respectively. However, the existing works retained limited performance. Hence, it is proved that the proposed work has a higher prominence than traditional methods.

5. Conclusions

This paper proposed a GDP-LSTM and SDQL-based finite state GT. The proposed GDP-LSTM effectively performs GT. An efficient SDQL was established to distinguish the update and error of the testing outcomes. The proposed model was assessed by using the DGC dataset. The proposed work utilized the GDF activation function and achieved significant accuracy and sensitivity rates of 98.89% and 98.97%, respectively, which proved the model’s reliability. The proposed SDQL retained a PT of 21,456 ms, which proved the low time complexity. Furthermore, the proposed SDQL was obtained with minimum MSE and MAPE of 1.018% and 0.305%, respectively, which suggests that the proposed framework is a less error-prone model. Along with that, the proposed SKGC attained a minimum clustering time of 56,942 ms for the mapping process of the analyzed data. Thus, the performance analysis showed that the proposed model had higher superiority in GT than existing works. However, the multiple segments of individual GUI are less concentrated in the proposed framework.
Future Scope: In the future, this work will be enhanced by considering the multiple segments of the GUI to upgrade the model’s consistency.

Author Contributions

Writing—original draft, S.K.; Writing—review & editing, N. and M.Y. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

Data are contained in the article.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Mishra, P. CT-GUI: A graphical user interface to perform calibration transfer for multivariate calibrations. Chemom. Intell. Lab. Syst. 2021, 214, 104338. [Google Scholar] [CrossRef]
  2. Ormeño, Y.I.; Panach, J.I.; Pastor, O. An empirical experiment of a usability requirements elicitation method to design GUIs based on interviews. Inf. Softw. Technol. 2023, 164, 107324. [Google Scholar] [CrossRef]
  3. Di Martino, S.; Fasolino, A.R.; Starace, L.L.L.; Tramontana, P. Comparing the effectiveness of capture and replay against automatic input generation for Android graphical user interface testing. Softw. Test. Verif. Reliab. 2021, 31, e1754. [Google Scholar] [CrossRef]
  4. Bahaweres, R.B.; Oktaviani, E.; Wardhani, L.K.; Hermadi, I.; Suroso, A.I.; Solihin, I.P.; Arkeman, Y. Behavior-driven development (BDD) Cucumber Katalon for Automation GUI testing case CURA and Swag Labs. In Proceedings of the 2nd International Conference on Informatics, Multimedia, Cyber, and Information System, ICIMCIS, Jakarta, Indonesia, 19–20 November 2020; pp. 87–92. [Google Scholar] [CrossRef]
  5. Walkinshaw, N. Improving Automated GUI Testing by Learning to Avoid Infeasible Tests. In Proceedings of the 2020 IEEE International Conference on Artificial Intelligence Testing, Oxford, UK, 3–6 August 2020; pp. 107–114. [Google Scholar] [CrossRef]
  6. Di Martino, S.; Fasolino, A.R.; Starace, L.L.L.; Tramontana, P. GUI testing of Android applications: Investigating the impact of the number of testers on different exploratory testing strategies. J. Softw. Evol. Process 2023, e2640. [Google Scholar] [CrossRef]
  7. Guo, W.; Shen, L.; Su, T.; Peng, X.; Xie, W. Improving Automated GUI Exploration of Android Apps via Static Dependency Analysis. In Proceedings of the 2020 IEEE International Conference on Software Maintenance and Evolution, Adelaide, SA, Australia, 28 September–2 October 2020; pp. 557–568. [Google Scholar] [CrossRef]
  8. Kilincceker, O.; Silistre, A.; Belli, F.; Challenger, M. Model-Based Ideal Testing of GUI Programs-Approach and Case Studies. IEEE Access 2021, 9, 68966–68984. [Google Scholar] [CrossRef]
  9. Silistre, A.; Kilincceker, O.; Belli, F.; Challenger, M.; Kardas, G. Models in Graphical User Interface Testing: Study Design. In Proceedings of the 2020 Turkish National Software Engineering Symposium, Istanbul, Turkey, 7–9 October 2020; pp. 1–6. [Google Scholar] [CrossRef]
  10. Doyle, J.; Saber, T.; Arcaini, P.; Ventresque, A. Improving mobile user interface testing with model driven monkey search. In Proceedings of the 2021 IEEE 14th International Conference on Software Testing, Verification and Validation Workshops, Porto de Galinhas, Brazil, 12–16 April 2021; pp. 138–145. [Google Scholar] [CrossRef]
  11. Pan, M.; Xu, T.; Pei, Y.; Li, Z.; Zhang, T.; Li, X. GUI-Guided Test Script Repair for Mobile Apps. IEEE Trans. Softw. Eng. 2022, 48, 910–929. [Google Scholar] [CrossRef]
  12. Yan, J.; Zhou, H.; Deng, X.; Wang, P.; Yan, R.; Yan, J.; Zhang, J. Efficient testing of GUI applications by event sequence reduction. Sci. Comput. Program. 2021, 201, 102522. [Google Scholar] [CrossRef]
  13. Pastor Ricós, F.; Slomp, A.; Marín, B.; Aho, P.; Vos, T.E.J. Distributed state model inference for scriptless GUI testing. J. Syst. Softw. 2023, 200, 111645. [Google Scholar] [CrossRef]
  14. Kumar, S.; Nitin; Yadav, M. Finite State GUI Testing with Test Case Prioritization Using Z-BES and GK-GRU. Appl. Sci. 2023, 13, 10569. [Google Scholar] [CrossRef]
  15. Kumar, S.; Nitin; Yadav, M. Finite state testing of graphical user interface using genetic algorithm. Int. J. Recent Innov. Trends Comput. Commun. 2023, 11, 282–287. [Google Scholar] [CrossRef]
  16. Ardito, L.; Coppola, R.; Leonardi, S.; Morisio, M.; Buy, U. Automated Test Selection for Android Apps Based on APK and Activity Classification. IEEE Access 2020, 8, 187648–187670. [Google Scholar] [CrossRef]
  17. Koroglu, Y.; Sen, A. Functional test generation from UI test scenarios using reinforcement learning for android applications. Softw. Test. Verif. Reliab. 2021, 31, e1752. [Google Scholar] [CrossRef]
  18. Coppola, R.; Morisio, M.; Torchiano, M.; Ardito, L. Scripted GUI testing of Android open-source apps: Evolution of test code and fragility causes. Empir. Softw. Eng. 2019, 24, 3205–3248. [Google Scholar] [CrossRef]
  19. Dataset. Available online: https://github.com/sd05031/Dataset_for_GUI_components (accessed on 7 January 2024).
  20. Xie, M.; Feng, S.; Xing, Z.; Chen, J.; Chen, C. UIED: A hybrid tool for GUI element detection. In Proceedings of the ESEC/FSE 2020 28th ACM Joint Meeting European Software Engineering Conference and Symposium on the Foundations of Software Engineering, Virtual, 8–13 November 2020; pp. 1655–1659. [Google Scholar] [CrossRef]
  21. Nguyen, V.; Le, B. RLTCP: A reinforcement learning approach to prioritizing automated user interface tests. Inf. Softw. Technol. 2021, 136, 106574. [Google Scholar] [CrossRef]
  22. White, T.D.; Fraser, G.; Brown, G.J. Improving random GUI testing with image-based widget detection. In Proceedings of the ISSTA 2019 28th ACM SIGSOFT International Symposium on Software Testing and Analysis, Beijing, China, 15–17 July 2019; pp. 307–317. [Google Scholar] [CrossRef]
  23. Xue, F.; Wu, J.; Zhang, T. Retracted: Visual Identification of Mobile App GUI Elements for Automated Robotic Testing. Comput. Intell. Neurosci. 2023, 2023, 9805091. [Google Scholar] [CrossRef]
  24. Zhu, P.; Li, Y.; Li, T.; Yang, W.; Xu, Y. GUI Widget Detection and Intent Generation via Image Understanding. IEEE Access 2021, 9, 160697–160707. [Google Scholar] [CrossRef]
Figure 1. The block design of the proposed work.
Figure 1. The block design of the proposed work.
Applsci 14 00549 g001
Figure 2. The framework of GDP-LSTM.
Figure 2. The framework of GDP-LSTM.
Applsci 14 00549 g002
Figure 3. Performance analysis according to (a) MSE and (b) MAPE.
Figure 3. Performance analysis according to (a) MSE and (b) MAPE.
Applsci 14 00549 g003
Figure 4. Processing time evaluation.
Figure 4. Processing time evaluation.
Applsci 14 00549 g004
Figure 5. Test case length vs. correctly classified percentage.
Figure 5. Test case length vs. correctly classified percentage.
Applsci 14 00549 g005
Figure 6. Performance assessment with respect to (a) accuracy, precision, F-measure, sensitivity, specificity, and recall; (b) False Positive Rate (FPR) and False Negative Rate (FNR).
Figure 6. Performance assessment with respect to (a) accuracy, precision, F-measure, sensitivity, specificity, and recall; (b) False Positive Rate (FPR) and False Negative Rate (FNR).
Applsci 14 00549 g006
Figure 7. Performance analysis.
Figure 7. Performance analysis.
Applsci 14 00549 g007
Table 1. Activity coverage analysis.
Table 1. Activity coverage analysis.
TechniqueActivity Coverage (%)
Proposed SDQL91.83
QL86.45
RL83.29
SARSA81.78
TDL77.05
Table 2. Clustering time analysis.
Table 2. Clustering time analysis.
MethodsClustering Time (ms)
Proposed SKGC56,942
SC66,556
HC85,863
DBSCAN98,866
KMC115,059
Table 3. Comparative analysis.
Table 3. Comparative analysis.
WorksTechniquesPT (ms)Precision (%)Accuracy (%)F-Measure (%)TC vs. CC (%)
Proposed modelGDP-LSTM and SDQL21,45698.9898.8999.2192.45
Xie et al. [20]YOLO-v322,800--24-
Nguyen and Le [21]RL----74.29%
White et al. [22]YOLO-v3-74---
Xue et al. [23]YOLO-v3-86.63-84.53-
Zhu et al. [24]LSTM--81--
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Kumar, S.; Nitin; Yadav, M. An Effective GDP-LSTM and SDQL-Based Finite State Testing of GUI. Appl. Sci. 2024, 14, 549. https://doi.org/10.3390/app14020549

AMA Style

Kumar S, Nitin, Yadav M. An Effective GDP-LSTM and SDQL-Based Finite State Testing of GUI. Applied Sciences. 2024; 14(2):549. https://doi.org/10.3390/app14020549

Chicago/Turabian Style

Kumar, Sumit, Nitin, and Mitul Yadav. 2024. "An Effective GDP-LSTM and SDQL-Based Finite State Testing of GUI" Applied Sciences 14, no. 2: 549. https://doi.org/10.3390/app14020549

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop