Universidade Federal de Goiás
There are a large variety of tools for application of many techniques of software testing. Likewise, there are a variety of frameworks that facilitate developing search techniques (e.g. Metaheuristics ). However, there are few tools available to the integration of these tools, which would be suitable for the application of SBST (Search Based Software Testing). Furthermore, such tools require an advanced knowledge of software testing techniques and optimization techniques.
Thinking about it, the SBST Group from Informatics Institute at Universidade Federal de Goiás, are developing the SBSTFrame focuses in the integration of these two types of tools to facilitate the application of search techniques in s of Software Testing area. The SBSTFrame plays the role of a top layer compared with software testing tools and frameworks of search techniques layer, to the communication between them could be done transparently to the user.
Currently, SBSTFrameacts only with selecting of test cases. To perform such a selection, the framework supports the following search techniques natively: EvolutionaryStrategy, GeneticAlgorithm, IslandModel, RandomAlgorithm and SteadyState. However, SBSTFrame is not restricted only to this scenario, therefore, can be extension of the framework to also act in different problems, such as test case generation, and increased search algorithms. Finally, we invite you to experience the SBSTFrame and make contributions. We expect the SBSTFrame can contribute to your project.
Requirements:
- Owning installed Java JDK and IDE environment;
- Import the Framework and configure correctly the build-path of the project;
- Ensure that all libraries are properly referenced.
The steps for using the framework are: 1) Set up the problem. 2) Set up the experiment. 3) Select the search technique. So far, the SBSTFrame supports the following techniques: EvolutionaryStrategy, GeneticAlgorithm, IslandModel, RandomAlgorithm and Steady.
1 - Set up the problem: Provide the file with the results of the execution of test cases, test criteria evaluated, according to the proposed layout as file "InputFile-Layout", in this distribution. If desired, the user can use one of the files (benchmarks) offered by SBSTFrame. As an example, Figure 1 illustrates the code for file use "Benchmarks.cal".
Figure 1: Example configuration problem.
2 - Set up the experiment: It's the execution of experiments on a problem environment Software Test and how will be the presentation of the results of the execution. To perform the experiment setup, simply instantiate an object of type "Experiment", where the construction parameters of the object the following attributes can be set, respectively:
- Number of executions of search technique (mandatory); - Maximum time, in seconds, for each run (mandatory); - Way to save the file with the results of the experiment (Optional - Default value: root folder of the project); - Generation or not the graph representing the execution of the experiment (Optional - Default value: True).
As an example, Figure 2 illustrates the process of setting up an experiment with mandatory values:
Figura 2: Configuration experiment example.
3 - Select the search technique: The user can select the techniques provided by SBSTFrame own, or use a proper technique. In this example, the use of a genetic algorithm, furnished by the framework itself and defined by the class "AbstractEvolutionaryAlgorithm", through the following parameters respectively shown:
- Population size; - Individual size; - Crossing rate; - Mutation rate.
Figure 3 illustrates an example of code that utilizes the genetic algorithm online:
Figura 3: Example of selecting a technique from SBSTFrame.
Other parameters that can be set by the user: The stop condition in this case is the number of generations (default = 100), and if the algorithm uses elitism (default = 1, yes). The snippet of example code can be seen in Figure 4.
Figura 4: Example of definition of not mandatory parameters.
At the end, just start the execution of the experiment by the method "run" through the parameter search technique set (in this case, the Genetic Algorithm), as illustrated in Figure 5.
Figura 5: Example of the experiment execution.
After running the experiment, a file will be generated "csv" in the location defined by the results obtained during the execution of the experiment and, if defined, the graph to display the results. Following these steps, the final code would be as illustrated in Figure 6 Thus, we find the reduction of code complexity using SBSTFrame.
Figure 6: Example of use of the final code for SBSTFrame.
Requirements:
- Owning installed Java JDK and IDE environment;
- Import the Framework and configure correctly the build-path of the project;
- Ensure that all libraries are properly referenced.
The steps for using the framework are: 1) Set up the problem. 2) Set up the experiment. 3) Select the search technique. So far, the SBSTFrame supports the following techniques: EvolutionaryStrategy, GeneticAlgorithm, IslandModel, RandomAlgorithm and SteadyState.
1 - Set up the problem: Provide the file with the results of the execution of test cases, test criteria evaluated, according to the proposed layout as file "InputFile-Layout", in this distribution. If desired, the user can use one of the files (benchmarks) offered by SBSTFrame. As an example, Figure 1 illustrates the code for file use "Benchmarks.cal".
Figure 1: Example of configuration problem.
2 - Set up the experiment: It's the execution of experiments on a problem environment Software Test and how will be the presentation of the results of the execution. To perform the experiment setup, simply instantiate an object of type "Experiment", where the construction parameters of the object the following attributes can be set, respectively:
Number of executions of search technique (mandatory); Maximum time, in seconds, for each run (mandatory); Way to save the file with the results of the experiment (Optional - Default value: root folder of the project); Generation or not the graph representing the execution of the experiment (Optional - Default value: True).
As an example, Figure 2 illustrates the process of setting up an experiment with mandatory values:
Figure 2: Example of configuration experiment.
3 - Select the search technique: The user can select the techniques provided by SBSTFrame own, or use a proper technique. In this example, the use of a genetic algorithm, furnished by the framework itself and defined by the class "AbstractEvolutionaryAlgorithm", through the following parameters respectively shown:
- Population size;
- Individual size;
- Crossing rate;
- Mutation rate.
Figure 3 illustrates an example of code that utilizes the genetic algorithm online:
Figure 3: Example selection technique provided by SBSTFrame.
Other parameters that can be set by the user: The stop condition in this case is the number of generations (default = 100), and if the algorithm uses elitism (default = 1, yes). The snippet of example code can be seen in Figure 4.
Figure 4: Example of definition of non-mandatory parameters.
At the end, just start the execution of the experiment by the method "run" through the parameter search technique set (in this case, the Genetic Algorithm), as illustrated in Figure 5.
Figure 5: Example of execution of the experiment.
After running the experiment, a file will be generated "csv" in the location defined by the results obtained during the execution of the experiment and, if defined, the graph to display the results.
Following these steps, the final code would be as illustrated in Figure 6 Thus, we find the reduction of code complexity using SBSTFrame.
Figure 6: Example of use of the final code for SBSTFrame.
Requirements:
- Owning installed Java JDK and IDE environment;
- Import the Framework and configure correctly the build-path of the project;
- Ensure that all libraries are properly referenced.
The steps for using the framework are: 1) Set up the problem. 2) Set up the experiment. 3) Select the search technique. So far, the SBSTFrame supports the following techniques: EvolutionaryStrategy, GeneticAlgorithm, IslandModel, RandomAlgorithm and SteadyState
1 - Set up the problem: Provide the file with the results of the execution of test cases, test criteria evaluated, according to the proposed layout as file "InputFile-Layout", in this distribution. If desired, the user can use one of the files (benchmarks) offered by SBSTFrame. As an example, Figure 1 illustrates the code for file use "Benchmarks.bubcorrecto".
Figure 1: Example of configuration problem.
2 - Set up the experiment: It's the execution of experiments on a problem environment Software Test and how will be the presentation of the results of the execution. To perform the experiment setup, simply instantiate an object of type "Experiment", where the construction parameters of the object the following attributes can be set, respectively:
- Number of executions of search technique (mandatory);
- Maximum time, in seconds, for each run (mandatory);
- Way to save the file with the results of the experiment (Optional - Default value: root folder of the project);
- Generation or not the graph representing the execution of the experiment (Optional - Default value: True).
As an example, Figure 2 illustrates the process of setting up an experiment with mandatory values:
Figure 2: Example of configuration experiment.
3 - Select a search technique: The user must select one of the techniques provided by SBSTFrame own, or use a proper technique. Figure 3 illustrates the use of an algorithm developed by the user. In this case, the user need only start the execution of the experiment, by the method "run" parameter passing by one of the benchmarks provided by SBSTFrame and an instance of the search technique the user's own.
Figure 3: Example of running the experiment with technique developed by the user.
Following these steps, the final code would be as illustrated in Figure 4 Thus, we find the reduction of code complexity using SBSTFrame.
Figure 4: Example of use of the final code for SBSTFrame.
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie.
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie.
Universidade Federal de Goiás
Instituto de Informática
Send us an email...
Instituto de Informática (INF) - UFG Alameda Palmeiras, Block D, Campus Samambaia Caixa Postal 131 - CEP 74001-970 - Goiânia - GO - Brazil
Developed by: Jailton Alkimin Louzada
This work SBSTFrame is under the license
Creative
Commons