Podrobná bibliografie
| Název: |
RUNTIME CLASS RECOMPILATION DURING MUTATION TESTING |
| Document Number: |
20220327045 |
| Datum vydání: |
October 13, 2022 |
| Appl. No: |
17/558279 |
| Application Filed: |
December 21, 2021 |
| Abstrakt: |
In mutation testing, source code is mutated at various positions, and test suites are run against the original object code and each version of the mutated object code, to determine the quality of test suites against arbitrary changes in the object code. The present disclosure provides a mutation test manager configured to initialize multiple computing threads configuring a computing host to perform parallel computation; mutate class files within context of each computing thread; recompile mutated class files independently in each respective computing thread to generate heterogeneous mutants; and execute pending unit tests against heterogeneous mutants independently in each respective computing thread. Consequently, the mutation testing process is decoupled from computational bottlenecks which would result from linear, sequential generation, compilation, and testing of each mutation, especially in the context of JVM® programming languages configured to generate class-rich object code. |
| Claim: |
1. A method, comprising: mutating, by a processor running a first computing thread among a plurality of computing threads each executing target object code in a target runtime environment, part of a class file of target source code; causing, by the processor, a compiler executing in the first computing thread to compile the class file containing the mutation without compiling other class files of the target source code, resulting in generating a mutant class object code; and replacing, by the processor, a non-mutant object class code of the executing target object code with the mutant class object code. |
| Claim: |
2. The method of claim 1, further comprising writing, by the processor, the target source code to non-volatile storage including the class file containing the mutation before configuring the compiler. |
| Claim: |
3. The method of claim 1, wherein mutating part of the class file comprises mutating a line of code of the class file. |
| Claim: |
4. The method of claim 1, wherein mutating part of the class file is performed in accordance with one of a plurality of mutation patterns of a mutation configuration. |
| Claim: |
5. The method of claim 1, wherein part of the class file or a different class file of the target source code is being mutated substantially concurrently, by the processor or by a different processor, in at least one other computing thread of the plurality of computing threads. |
| Claim: |
6. The method of claim 1, wherein the compiler is configured by the processor executing a compiler script including a parameterized call to the compiler. |
| Claim: |
7. The method of claim 1, further comprising executing, by the processor in the first computing thread, pending unit tests among a test suite against the executing target object code after replacing the non-mutant object class code. |
| Claim: |
8. A computing host comprising: one or more processors; and memory communicatively coupled to the one or more processors, the memory storing computer-executable modules executable by the one or more processors that, when executed by the one or more processors, perform associated operations, the computer-executable modules comprising: a compiler module; and a mutation test managing module further comprising: a class file mutating submodule configured to mutate, in a first computing thread among a plurality of computing threads each executing target object code in a target runtime environment, part of a class file of target source code; a compiler configuring submodule configured to configure the compiler module executing in the first computing thread to compile the class file containing the mutation without compiling other class files of the target source code, resulting in generating a mutant class object code; and a class loading submodule configured to replace a non-mutant object class code of the executing target object code with the mutant class object code. |
| Claim: |
9. The computing host of claim 8, wherein the mutation test managing module further comprises a class file read/write submodule configured to write the target source code to non-volatile storage including the class file containing the mutation before the compiler configuring submodule configures the compiler. |
| Claim: |
10. The computing host of claim 8, wherein the class file mutating submodule is configured to mutate part of the class file by mutating a line of code of the class file. |
| Claim: |
11. The computing host of claim 8, wherein the class file mutating submodule is configured to mutate part of the class file in accordance with one of a plurality of mutation patterns of a mutation configuration. |
| Claim: |
12. The computing host of claim 8, wherein the class file mutating submodule is configured to mutate part of the class file or a different class file of the target source code substantially concurrently among the plurality of computing threads. |
| Claim: |
13. The computing host of claim 8, wherein the compiler configuring submodule is configured to configure the compiler by executing a compiler script including a parameterized call to the compiler. |
| Claim: |
14. The computing host of claim 8, wherein the computer-executable submodules further comprise a test executing submodule configured to execute, in the first computing thread, pending unit tests among a test suite against the executing target object code after the class loading submodule replaces the non-mutant object class code. |
| Claim: |
15. A computer-readable storage medium storing computer-readable instructions executable by one or more processors, that when executed by the one or more processors, cause the one or more processors to perform operations comprising: mutating, in a first computing thread among a plurality of computing threads each executing target object code in a target runtime environment, part of a class file of target source code; configuring a compiler executing in the first computing thread to compile the class file containing the mutation without compiling other class files of the target source code, resulting in generating a mutant class object code; and replacing a non-mutant object class code of the executing target object code with the mutant class object code. |
| Claim: |
16. The computer-readable storage medium of claim 15, wherein the operations further comprise writing the target source code to non-volatile storage including the class file containing the mutation before configuring the compiler. |
| Claim: |
17. The computer-readable storage medium of claim 15, wherein mutating part of the class file comprises mutating a line of code of the class file. |
| Claim: |
18. The computer-readable storage medium of claim 15, wherein mutating part of the class file is performed in accordance with one of a plurality of mutation patterns of a mutation configuration. |
| Claim: |
19. The computer-readable storage medium of claim 15, wherein the operations further comprise part of the class file or a different class file of the target source code being mutated substantially concurrently in at least one other computing thread of the plurality of computing threads. |
| Claim: |
20. The computer-readable storage medium of claim 15, wherein the operations further comprise executing, in the first computing thread, pending unit tests among a test suite against the executing target object code after replacing the non-mutant object class code. |
| Current International Class: |
06; 06; 06 |
| Přístupové číslo: |
edspap.20220327045 |
| Databáze: |
USPTO Patent Applications |