This non-provisional application claims priority of Taiwan patent application No. 109132102, filed on 17 Sep. 2020, included herein by reference in its entirety.
The present invention relates to software verification, and in particular, to a verification system providing software verification and a verification method of the verification system.
Software verification is a process for use in software engineering to ensure code quality and functionality. After program code is completed, a software developer may submit the program code, write corresponding test program code and/or assign compiler parameters for various types of verifications. The various types of verifications such as format verifications, quality verifications, compilation verifications and basic function verifications are often required to be verified manually and separately, and are required to be set in various packages and executed manually, resulting in low verification efficiency.
According to an embodiment of the invention, a verification system includes a local server, a plurality of verification platforms and a main server. A verification method for use in the verification system includes the local server receiving program code to compile the program code into a verification image, the local server selecting a verification platform from the plurality of verification platforms according to the type of the program code, the local server writing the verification image into the selected verification platform, the selected verification platform performing a set of tests on the verification image to generate a verification report, and the main server generating an updated image according to the verification report.
According to another embodiment of the invention, a verification system includes a local server, a plurality of verification platforms and a main server. One of the plurality of verification platforms is configured to perform a set of tests on a verification image to generate a verification report. The local server is coupled to the verification platforms and is configured to receive program code to compile the program code into the verification image, select the verification platform from the plurality of verification platforms according to the type of the program code, and write the verification image into the verification platform. The main server is coupled to the plurality of verification platforms and is configured to generate an updated image according to the verification report.
These and other objectives of the present invention will no doubt become obvious to those of ordinary skill in the art after reading the following detailed description of the preferred embodiment that is illustrated in the various figures and drawings.
The verification system 1 may include a local server 10, a plurality of verification platforms 121-12N, and a main server 14, where N may be, but is not limited to, an integer greater than 2 and may represent the next digit after the number 12. The local server 10 is coupled to the verification platforms 121-12N and the verification platforms 121-12N are coupled to the main server 14.
A verification environment may be preset in each of the verification platforms 121-12N to perform a set of tests of a respective verification type thereof, where the verification type may be associated with an application and/or a protocol. For example, the verification type may be associated with a low-level function of a TV application such as Android kernel program code, and the verification type may be associated with a high-level function of the TV application such as an Android service program code, and the verification type may be associated with a low-level function of a wireless network application such as a wireless network driver. The verification environment may include parameters, software and hardware, e.g., parameters, software, and hardware for testing a TV application.
The user may submit the program code 16 to the local server 10 via user interface software of the local server 10. The local server 10 may receive the program code 16 and select at least one verification platform from the verification platforms 121-12N to verify the function of the program code 16.
The selected verification platform may perform a set of tests of the matching verification type on the verification image to generate a verification report, and write the verification report into a database in the main server 14. For example, when the verification type is a TV application, a set of tests of the verification type may include a TV sweep test for a specific country, a TV channel switching test for the specific country, a picture quality test, a booting test, an operating environment test, a TV service test and other tests, and the verification report may include results of each test in the set of tests. In some embodiments, the local server 10 may also write the compilation result into the verification report in the database of the main server 14. In some embodiments, the main server 14 may compute a verification score of the program code 16 according to the verification report in the database. When the program code 16 passes the compilation or the set of tests, the main server 14 may increase the verification score, and the verification system 1 may continue with the subsequent processes; when the program code 16 fails the compilation or fails a test in the set of tests, the main server 14 may reduce the verification score, and the verification system 1 may stop the subsequent processes and notify the submitter of the program code 16 and the person responsible for the project may check this matter. For example, if the program code 16 is compiled successfully, the main server 14 may increase the verification score by 1 point (the score only serves as an example but not a limitation, and the same is applicable to the following examples), the local server 10 and the selected verification platform may continue with the subsequent verification platform selection process and test process; if the program code 16 is failed to compile, the main server 14 may deduct the verification score by 1 point, and the local server 10 may stop the subsequent verification platform selection process and test process. The local server 10 may read the verification report or the verification score from the main server 14. When the verification report indicates that the program code 16 has successfully passed all the tests or the program code 16 took a full verification score, the local server 10 may update the program code 16 to the main server 14, and the main server 14 may generate an updated image file 18 according to the program code 16; when the verification report indicates that the program code 16 has failed one or more tests or the program code 16 failed to achieve the full verification score, the local server 10 may not update the program code 16 to the main server 14 and may notify the submitter of the program code 16 and the person responsible for the project may check this matter, and the main server 14 may generate an updated image file 18 according to the program code previously passed the set of tests. A plurality of pieces of verified program code may be stored in the main server 14, and each piece of verified program code may be associated with identical or different applications or protocols. In some embodiments, when the verification report indicates that the program code 16 has successfully passed the set of tests, the main server 14 may generate the updated image 18 according to the program code 16 and other pieces of verified program code. The other verified program code and program code 16 may be associated with different applications or protocols.
The verification system 1 may assign corresponding verification platforms to perform different tests according to the type of the program code 16, realizing multi-pipeline and multi-test verification, and providing efficient test management and verification platform management. In addition, the verification system 1 may further conduct a verification process of programming rules via the static analysis tool 100 in the local server 10 to ensure the code quality of the program code 16.
Step S502: The local server 10 receives the program code 16 to compile the program code 16 into a verification image;
Step S504: The local server 10 selects a verification platform from the plurality of verification platforms 121-12N according to the type of the program code 16;
Step S506: The local server 10 writes the verification image into the selected verification platform 12n;
Step S508: The selected verification platform 12n performs the set of tests on the verification image to generate the verification report;
Step S510: The main server 14 generates the updated image 18 according to the verification report.
The explanation for Steps S502-S510 has been provided in the preceding paragraphs, and will be omitted here for brevity. The verification method 500 assigns verification platforms according to the type of the program code 16 to perform corresponding tests, realizing multi-pipeline and multi-test task verifications, and providing efficient test management and verification platform management.
Step S602: The local server 10 receives the program code 16;
Step S604: The local server 10 determines whether the program code 16 conforms to at least one set of programming rules. If the determination result shows YES, proceed to Step S606; if the determination result shows NO, exit the verification method 600;
Step S606: The local server 10 compiles the program code 16 into the verification image;
Step S608: The local server 10 selects a verification platform from the plurality of verification platforms 121-12N according to the type of the program code 16;
Step S610: The local server 10 writes the verification image into the selected verification platform;
Step S612: The selected verification platform performs a set of tests on the verification image to generate a verification report;
Step S614: The local server 10 determines whether the verification report indicates that the verification image of the program code 16 has successfully passed the set of tests. If the determination result shows YES, proceed to Step S616; if the determination result shows NO, exit the verification method 600;
Step S616: The main server 14 generates the updated image 18 according to the program code 16 and other verified program code.
The explanation for Steps S602-S616 has been provided in the preceding paragraphs, and will be omitted here for brevity. The verification method 600 integrates the verification procedures of the programming rules before the compilation and the verification procedures of the verification platform after the compilation to ensure the program code quality and functionalities of the program code 16, realizing the multi-pipelines and multi-test verifications, and providing efficient test management and verification platform management.
Those skilled in the art will readily observe that numerous modifications and alterations of the device and method may be made while retaining the teachings of the invention. Accordingly, the above disclosure should be construed as limited only by the metes and bounds of the appended claims.
Number | Date | Country | Kind |
---|---|---|---|
109132102 | Sep 2020 | TW | national |