Code integration test method, device and system, electronic equipment, computer storage medium and computer program product
By obtaining push operation feedback from the code hosting platform and performing merging checks and dynamic functional tests, the problem of front-end design engineers not being able to detect code errors in a timely manner was solved, improving the reliability of code management and the efficiency of chip design.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- BEIJING YOUZHUJU NETWORK TECH CO LTD
- Filing Date
- 2024-10-30
- Publication Date
- 2026-05-01
AI Technical Summary
In the front-end development process of chip design, errors in the code submitted by front-end design engineers are not detected early, which slows down the rework and verification process, affects the chip release time, and the code hosting management is unreliable.
By using code integration testing methods, we obtain push feedback on updated branch code from the code hosting platform, perform merging checks, and notify the merger after passing the checks. We also dynamically test the merged code to improve the reliability of code management.
This improved the reliability and management efficiency of code integration, reduced the workload of later verification, and ensured code quality and chip design stability.
Smart Images

Figure CN121958076A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, and more particularly to a code integration testing method, apparatus and system, electronic device, computer storage medium, and computer program product. Background Technology
[0002] In the field of chip design, front-end design (FE) is a crucial step in translating logic design into a physical design that can be implemented on silicon. Front-end design engineers (DEs) are responsible for tasks such as logic synthesis, timing analysis, placement, and routing. These stages demand extremely high levels of detail; even a small oversight can cause the chip to malfunction or fail to meet performance standards. However, even in the highly specialized field of chip design, front-end DEs can make basic syntax or logic errors when submitting code. If these errors are not detected early, they can lead to costly rework later and even affect the chip's release date.
[0003] In the front-end development process of chip design, code integration solutions such as Continuous Integration (CI) play a crucial role. As front-end design engineers complete the branch coding of specific development functional modules, the branch code is submitted to the code hosting platform for branch merging.
[0004] Since the Design Verification (DV) team is responsible for verifying the correctness of the design, when there are errors in the code submitted by the front-end design engineers, the design verification team needs to spend a lot of time identifying and correcting these problems. This not only slows down the verification process, but also reduces the reliability of the code hosting management. Summary of the Invention
[0005] In view of the above, embodiments of this disclosure provide a code integration testing method, apparatus and system, electronic device, computer storage medium, and computer program product to solve the above problems.
[0006] According to a first aspect of the present disclosure, a code integration testing method is provided, comprising: obtaining operation event feedback of a push operation of an update branch code of a development functional module from a code hosting terminal; performing a merge check for merging the update branch code into a target branch code of the development functional module based on the operation event feedback; notifying the code hosting terminal to merge the update branch code into the target branch code when the merge check result indicates that the check has passed; obtaining the merged target branch code from the code hosting terminal, and performing dynamic functional testing on the merged target branch code.
[0007] According to a second aspect of the present disclosure, a code integration testing apparatus is provided, comprising: an acquisition module for acquiring operation event feedback of a push operation of an update branch code of a development function module from a code hosting terminal; an inspection module for performing a merge check to merge the update branch code into a target branch code of the development function module based on the operation event feedback; a notification module for notifying the code hosting terminal to merge the update branch code into the target branch code when the result of the merge check indicates that the check has passed; and a testing module for acquiring the merged target branch code from the code hosting terminal and performing dynamic functional testing on the merged target branch code.
[0008] According to a third aspect of the present disclosure, a code integration testing system is provided, comprising: a code hosting terminal; and a code integration testing apparatus according to the second aspect.
[0009] According to a fourth aspect of the present disclosure, an electronic device is provided, comprising: a processor, a memory, a communication interface, and a communication bus, wherein the processor, the memory, and the communication interface communicate with each other via the communication bus; the memory is used to store at least one executable instruction, the executable instruction causing the processor to perform the method as described in the first aspect.
[0010] According to a fifth aspect of the present disclosure, a computer storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the method described in the first aspect.
[0011] According to a sixth aspect of the present disclosure, a computer program product is provided, including computer instructions that, when executed by a processor, implement the method as described in the first aspect.
[0012] In the scheme of this embodiment, the operation event feedback of the push operation on the code hosting terminal is used to trigger the merging check of the updated branch code to the target branch code, and the code merging is performed when the merging check passes, which improves the reliability of code management on the code hosting terminal. In addition, the target branch code after merging is obtained and dynamic functional tests are performed, which further improves the reliability of code management of the target branch code after merging. Attached Figure Description
[0013] To more clearly illustrate the technical solutions in the embodiments or related technologies of this disclosure, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments recorded in the embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings.
[0014] Figure 1 This is a schematic architecture of a code integration testing system applicable to some embodiments of this disclosure.
[0015] Figure 2 The flowchart illustrates the steps of a code integration testing method according to other embodiments of this disclosure.
[0016] Figure 3 for Figure 2 A schematic block diagram of the code integration testing system applicable to the embodiments.
[0017] Figure 4 for Figure 2 A schematic flowchart illustrating code integration testing methods for some specific examples of the embodiments.
[0018] Figure 5 This is a structural block diagram of a code integration testing apparatus for some other embodiments of this disclosure.
[0019] Figure 6 This is a schematic diagram of the structure of an electronic device according to some other embodiments of the present disclosure. Detailed Implementation
[0020] To enable those skilled in the art to better understand the technical solutions in the embodiments of this disclosure, the technical solutions in the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this disclosure, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this disclosure should be protected by this disclosure.
[0021] The scope of [P-137012-CN-PRI-1][HS2410875CCN].
[0022] The specific implementation of the embodiments of this disclosure will be further described below with reference to the accompanying drawings. Figure 1 This is a schematic architecture of a code integration testing system applicable to some embodiments of this disclosure. Figure 1 The code integration testing system comprises a development terminal 10, a code hosting terminal 20, and a code integration testing terminal 30. The system is designed to provide a stable, reliable, and efficient integration testing platform to support the front-end work of chip design, from the initial design phase to the final manufacturable design phase.
[0023] Specifically, Development Terminal 10 is used for front-end development of chip design. It is equipped with a high-performance processor, ample memory, and a high-speed storage system to support complex design and simulation tasks. Furthermore, Development Terminal 10 is equipped with various Electronic Design Automation (EDA) tools to assist in different stages of the design process, such as logic synthesis, placement and routing, timing analysis, and power optimization. EDA tools typically include modules such as Synthesis, Place, Route, and Verification, which can process Hardware Description Language (HDL) code and translate it into a physical design that can be implemented on silicon. To achieve efficient collaboration and code management, the design team also uses code hosting platforms such as GitLab and continuous integration (CI) servers for version control of the code, automating the build and testing process to ensure code quality and timely feedback.
[0024] Furthermore, code hosting platforms such as GitLab and GitHub are adopted by chip design teams to improve code quality. These platforms not only provide code storage and management functions but also support automated continuous integration processes. Specifically, GitLab's Webhook is a server-to-server callback notification mechanism that allows GitLab to send HTTP POST requests to predefined URLs when specific events occur, such as code pushes, the creation or closure of merge requests. These event-triggered Webhooks can be used to automatically start build tasks in Jenkins, enabling continuous integration. For example, when a developer pushes an update to a GitLab repository, GitLab can notify the Jenkins server via a Webhook, triggering Jenkins to execute predefined build scripts and test suites. This integration method ensures that code changes are quickly built and tested, allowing for timely detection and fixing of issues, improving development efficiency and code quality. In addition, GitLab provides other components such as Merge Requests to manage code inspection and merging processes, and pipelines to visualize and automate the entire CI process. Through the collaborative work of these components, GitLab provides software development teams with a powerful set of tools to support modern agile development practices.
[0025] Furthermore, the code integration testing terminal 30 can be implemented as a code integration testing device. The code integration testing terminal 30 is used to automatically run a series of checks and tests after code submission, including static code analysis, code style checks, and syntax checks. In this way, potential errors can be identified and corrected as early as possible, reducing the workload of the DV team in the later verification process. The code integration testing terminal 30, through communication with the code hosting terminal 30, supports branch code management, code review, and merge requests—all effective tools for ensuring code quality and promoting team collaboration. Code reviews and merge requests ensure that code changes undergo rigorous review and testing before being merged into the main branch, thus preventing immature or defective code from affecting the entire project.
[0026] Figure 2 The code integration testing methods of some other embodiments of this disclosure are shown. Figure 2 Code integration testing methods include:
[0027] S210: Operation event feedback for the push operation of the updated branch code of the development function module obtained from the code hosting terminal.
[0028] It should be understood that a development functional module can be any module in the functional architecture of a development project. For example, a development functional module can be a top-level functional module (i.e., a top-level module) or a lower-level functional module of a top-level functional module. For example, lower-level functional modules include, but are not limited to, subsystem modules (i.e., subsystem modules) and sub-modules (e.g., block modules).
[0029] It should also be understood that, as the starting point for automating the development process, developers can push updated branch code of developed functional modules to the code hosting platform. The code hosting platform then sends feedback information about the push event to CI devices or systems such as Jenkins via a webhook mechanism. This feedback triggers the subsequent automated process of code integration testing, ensuring that the updated branch code can be quickly integrated and tested. It should also be understood that the automated process of code integration testing can be implemented using script code or other types of code and configured as a code integration testing component on the development side.
[0030] S220: Based on the operation event feedback, perform a merge check to merge the updated branch code into the target branch code of the development feature module.
[0031] It should be understood that CI devices or systems such as Jenkins, upon receiving push operation event feedback, can automatically execute a series of predefined inspection tasks, such as code style review, basic logic check, programming language syntax check, static code analysis, etc., to ensure that the commit of updated branch code conforms to project standards and reduce integration errors and potential defects.
[0032] S230: When the merge check result indicates that the check has passed, notify the code hosting provider to merge the updated branch code into the target branch code.
[0033] It should be understood that once the merge check in a CI appliance or system, such as Jenkins, confirms that the code is error-free, the CI appliance or system will send a command to a code hosting provider, such as GitLab, requesting that the updated branch be merged into the target branch, such as the main branch. This notification can be implemented, for example, through API calls configured for the code hosting provider by the CI appliance or system, such as Jenkins, or through specific webhook callback functions.
[0034] S240: Retrieve the merged target branch code from the code hosting provider and perform dynamic functional testing on the merged target branch code.
[0035] It should be understood that after the updated branch code is merged with the target branch code, CI devices or systems such as Jenkins will pull the latest merged code and initiate dynamic functional tests such as integration tests and regression tests to ensure that the changes to the updated branch code do not alter the application's existing functionality, thus maintaining the application's stability and reliability. In some examples, the test results will be fed back to the development team. If the tests pass, the merged code can continue to be implemented; if the tests fail, further investigation and fixing of the issues are required.
[0036] In the scheme of this embodiment, the operation event feedback of the push operation on the code hosting terminal is used to trigger the merging check of the updated branch code to the target branch code, and the code merging is performed if the merging check passes, which improves the reliability of code management on the code hosting terminal. In addition, the merged target branch code is obtained for dynamic function execution.
[0037] [P-137012-CN-PRI-1][HS2410875CCN] can be tested, further improving the reliability of code management for the merged target branch code.
[0038] In some examples, such as Figure 3As shown, the updated branch code is the development branch code, and the target branch code is the main branch code. The development client 10 triggers a merge request by pushing the updated branch code to the code hosting client 20. The code hosting client 20 manages various development functional modules. Figure 3 Either development function module 1 or development function module 2 shown can be a top-level function or a lower-level function module. When the code hosting terminal 20 receives the development branch code of any development function module, it sends an event feedback to the code integration testing terminal 30, triggering the merging detection module to perform a merging check on the development branch code. After the merging check passes, it sends feedback to the code hosting terminal 20 indicating that the check has passed, so that the code hosting terminal 20 merges the development branch code into the main branch code belonging to the same development function module.
[0039] Furthermore, after detecting a branch code merging operation, the code integration test terminal 30 performs regression testing on the merged main branch code locally or by calling the test configuration on the development terminal 10, and obtains the regression test results. For example, as an example of obtaining the merged target branch code from the code hosting terminal, the merging operation of the update branch code into the target branch code can be monitored on the code hosting terminal, and then the merged target branch code can be obtained from the code hosting terminal. In other words, by monitoring the merging operation, the merged target branch code can be obtained in a timely and reliable manner.
[0040] Furthermore, as an example of performing dynamic functional testing on the merged target branch code, regression test cases can be obtained for the merged target branch code. These regression test cases include test input data related to the development functional module code. This test input data is then input into the merged target branch code to obtain the results of the dynamic functional testing. In other words, regression testing can efficiently detect the reliability of the merged target branch code. By using test input data related to the development functional module code, reliable and efficient regression testing is performed on the merged target branch code, improving the efficiency of dynamic functional testing.
[0041] Furthermore, when the code integration test terminal 30 performs dynamic functional testing on the merged target branch code, it can also send a close operation request with operation event feedback to the code hosting terminal 20 when the dynamic functional test result indicates that the test has passed. In other words, after the dynamic functional test passes, it indicates that both the merging check of the updated branch code and the dynamic functional test have passed, saving communication interface resources on the code hosting terminal.
[0042] It should be understood that the code integration test terminal 30 can perform the merging check of the updated branch code locally. Alternatively, the merging check can be performed by calling the test configuration of the development terminal 10. Without loss of generality, as an example of performing a merging check to merge the updated branch code into the target branch code of the development function module based on operation event feedback, a merging check request for the updated branch code can be sent to the development terminal that pushed the updated branch code based on the operation event feedback, and the result of the merging check returned by the development terminal can be received, wherein the merging check request instructs the development terminal to perform a merging check to merge the updated branch code into the target branch code.
[0043] In other words, the code integration testing device can send a merge check request to the development team that pushes the updated branch code and receive the merge check result from the development team. This avoids the process of obtaining the updated branch code targeted by the merge check, and eliminates the need to directly execute the merge check through the script program of the code integration testing device, thus saving computing resources.
[0044] [P-137012-CN-PRI-1][HS2410875CCN] and communication resources.
[0045] In other embodiments, during the merging check operation, based on operation event feedback, a merging check is performed to merge the updated branch code into the target branch code of the development function module. More specifically, based on operation event feedback, it can be determined whether the updated branch code and the target branch code meet the static code check conditions. Then, if the updated branch code and the target branch code meet the static code check conditions, a static code check is performed to merge the updated branch code into the target branch code of the development function module.
[0046] In other words, the merging check criteria characterize the necessity and priority of the merging check. Static code checking is performed when both the updated branch code and the target branch code meet the static code check criteria, thus improving the reliability of the merging check. When the merging check criteria are not met, a check method with less data processing can be used compared to static code checking.
[0047] In other cases, the updated branch code may or may not be development branch code; the target branch code may or may not be main branch code. When the updated branch code is development branch code and the target branch code is the main branch code of the development functional module, it indicates that the merging of the development branch code is highly reliable, and the main branch code has a significant impact on the code of each branch in the development functional module. When the above static code checking conditions are met, static code checking can identify logical errors and programming language syntax errors in the development branch code. Accordingly, when the above static code checking conditions are met, static code checking is performed, for example, checking for code style, programming language syntax errors, and basic logical errors.
[0048] In other scenarios, as an example of performing merging checks based on operational event feedback, the merging check result can be directly determined as passed if the target branch code is not the main branch code of the development module. In other words, if the target branch code is not the main branch code of the development module, it indicates that merging the update branch code into a non-main branch code has a relatively small impact on the non-main branch code. Therefore, directly determining the merging check result as passed helps improve the efficiency of code integration testing.
[0049] In other scenarios, as an example of performing merging checks based on operation event feedback, if the updated branch code is not a development branch, the merging check result can be directly determined as a failure, and a close operation request with operation event feedback can be sent to the code hosting provider. In other words, if the updated branch code is not a development branch, it indicates that the necessity of merging the non-development branch code into the main branch code is low; therefore, directly determining the merging check result as a failure ensures the reliability of code management on the code hosting provider.
[0050] Figure 4 for Figure 2 A schematic flowchart illustrating code integration testing methods for some specific examples of the embodiments. Figure 4 The code integration testing method illustrates the data interaction and data flow control between the development end 10, the code hosting end 20, and the code integration testing device 30. Figure 4 The code integration testing method includes the following steps:
[0051] Step S11: Developer 10 pushes the updated branch code of the development module to code hosting 20. After completing the development of the module locally, the developer executes `git add .` to add changes, `git commit -m "description"` to commit the changes, and then uses `git push origin branch_name` to push the updates to the GitLab remote repository. After pushing, the developer can use...
[0052] [P-137012-CN-PRI-1][HS2410875CCN] Use the GitLab user interface to confirm the push status and check for any error messages. Then proceed to step S21.
[0053] Step S21: The code hosting server 20 determines whether there are code conflicts between the updated branch code and other code in the development module. For example, GitLab checks for conflicts when attempting automatic merging and highlights the conflict area in the console output. If yes, proceed to step S12; if no, proceed to step S31. For example, if a conflict is detected, GitLab will stop the merging process and send an event notification containing conflict information to Jenkins via a webhook.
[0054] Step S12: On the development side, resolve the code conflict by manually modifying the code or deleting the conflict. For example, the developer resolves the conflict in their local editor based on the conflict information provided by GitLab, marks the resolved file as resolved using gitadd, and then git commits and git pushes again to update the remote branch.
[0055] Step S31: The code integration testing device 30 receives operation event feedback from the code hosting terminal 20 in response to the push operation. For example, Jenkins is configured with triggers to listen for webhook events from GitLab. Once a push event is received, Jenkins will evaluate the build conditions and check if there are any new merge requests or code pushes.
[0056] Step S32: The code integration testing device 30 determines whether the target branch code is the main branch code of the development functional module. For example, Jenkins determines whether the target branch is a main branch, such as main or master, based on the configuration. This can be achieved by analyzing the data in the Webhook event. If yes, proceed to step S33; if no, proceed to step S22.
[0057] Step S22: When the target branch code is not the main branch code of the development function module, the code hosting terminal 20 directly determines the merge check result as passed and merges the updated branch code into the non-main branch code. For example, GitLab automatically merges the updated branch into the target branch and notifies Jenkins of the merge result via Webhook, so Jenkins can update the build status accordingly. Without loss of generality, when the target branch code is not the main branch code of the development function module, the merge check result is directly determined as passed.
[0058] Step S33: The code integration testing device 30 determines whether the updated branch code is a development branch code. For example, Jenkins determines whether it is a development branch based on the branch name or other identifiers, and starts the corresponding build process according to the project configuration. If yes, proceed to step S34; if no, proceed to step S23. Without loss of generality, when the updated branch code is not a development branch code, the merge check result is directly judged as a failed check, and a close operation request is sent to the code hosting terminal as feedback of the operation event.
[0059] Step S23: The code hosting client 20 directly determines the merge check result as failed and sends a close operation request to the code hosting client to close the code merge check. For example, GitLab updates the merge request status to failed and notifies Jenkins to close the relevant CI process. Jenkins then stops building and updates the status accordingly.
[0060] Step S34: When the static code analysis conditions are met, the code integration testing device 30 performs a static code analysis on the updated branch code to determine whether the static code analysis passes. For example, Jenkins runs a pre-configured static code analysis tool to check code quality and generate a report during the build process. If yes, proceed to step S25; if no, proceed to step S24. Without loss of generality, when the updated branch code is the development branch code and the target branch code is the main branch code of the development functional module, it is determined that the static code analysis conditions are met. Then, when the updated branch code and the target branch code meet the static code analysis conditions, a static code analysis is performed to merge the updated branch code into the target branch code of the development functional module.
[0061] Step S24: The code hosting server 20 ends the CI test task and continues to execute step S13. For example, GitLab marks the CI process as failed and notifies Jenkins to end the current task. Jenkins updates the build status to failed and notifies the development team.
[0062] Step S25: The code hosting terminal 20 merges the updated branch code into the main branch code and continues to execute steps S13 and S35. For example, GitLab completes the merge operation and notifies Jenkins of the successful merge via a webhook, and Jenkins updates the build status to successful.
[0063] Step S13: On the development side 10, CI test result notifications are executed. For example, the CI test results can be displayed to the user through the user interface of the test program executing the code integration tests, or the user can be notified of the CI test results via a messaging program. For instance, developers can view test results through the Jenkins interface or receive test result notifications through an integrated instant messaging system such as Slack. Jenkins can also send test summaries via email to ensure team members receive timely feedback.
[0064] Step S35: The code integration testing apparatus 30 performs regression testing on the merged main branch code. For example, Jenkins starts a regression test suite to verify whether changes to the main branch code affect existing functionality and provides a test report. Jenkins updates the build status based on the regression test results and notifies GitLab of the test results via Webhook when necessary. Without loss of generality, the code integration testing apparatus 30 monitors the code hosting end for merging the updated branch code into the target branch code, and then obtains the merged target branch code from the code hosting end. Additionally, during regression testing, regression test cases for the merged target branch code can be obtained. These regression test cases include test input data related to the development functional module code. The test input data is then input into the merged target branch code to obtain the results of dynamic functional testing. When the dynamic functional test results indicate that the test has passed, a close operation request with operation event feedback is sent to the code hosting end.
[0065] The following will combine Figure 5 To describe a code integration testing apparatus of other embodiments of this disclosure. Figure 5 The code integration testing device 500 includes:
[0066] Get module 510, retrieve operation event feedback of push operation of updated branch code of development function module from code hosting terminal.
[0067] The inspection module 520 performs a merge check to merge the updated branch code into the target branch code of the development function module based on the operation event feedback.
[0068] The notification module 530, when the merge check result indicates that the check has passed, notifies the code hosting end to merge the updated branch code into the target branch code.
[0069] The test module 540 obtains the merged target branch code from the code hosting terminal and performs dynamic functional testing on the merged target branch code.
[0070] In the scheme of this embodiment, the operation event feedback of the push operation on the code hosting terminal is used to trigger the merging check of the updated branch code to the target branch code, and the code merging is performed when the merging check passes, which improves the reliability of code management on the code hosting terminal. In addition, the target branch code after merging is obtained and dynamic functional tests are performed, which further improves the reliability of code management of the target branch code after merging.
[0071] In other embodiments, the checking module is specifically used to: send a merge check request for the updated branch code to the development end that pushed the updated branch code based on the operation event feedback, and receive the merge check result returned by the development end, wherein the merge check request instructs the development end to merge the updated branch code into the merge check of the target branch code.
[0072] In other embodiments, the checking module is specifically used to: determine whether the updated branch code and the target branch code meet the static code check conditions based on the operation event feedback; and when the updated branch code and the target branch code meet the static code check conditions, perform a static code check to merge the updated branch code into the target branch code of the development function module.
[0073] In other embodiments, the checking module is further configured to: determine that the code static check condition is met when the updated branch code is the development branch code and the target branch code is the main branch code of the development function module.
[0074] In other embodiments, the detection module is also used to: directly determine the result of the merge check as passed when the target branch code is not the main branch code of the development function module.
[0075] In other embodiments, the detection module is further configured to: when the updated branch code is not the development branch code, directly determine the result of the merge check as a failed check, and send a close operation request of the operation event feedback to the code hosting terminal.
[0076] In other embodiments, the testing module is specifically used to: obtain regression test cases for the merged target branch code, the regression test cases including test input data related to the development function module code; input the test input data into the merged target branch code to obtain the results of the dynamic function test.
[0077] In other embodiments, the testing module is further configured to: send a shutdown operation request of the operation event feedback to the code hosting terminal when the result of the dynamic functional test indicates that the test has passed.
[0078] In other embodiments, the acquisition module is specifically used to: monitor the merge operation of the code hosting terminal into the target branch code; and acquire the target branch code merged into the target branch code through the merge operation from the code hosting terminal.
[0079] The specific implementation of each module in the code integration testing device can be found in the description of the corresponding steps in the above-described code integration testing method embodiments, and has corresponding beneficial effects, which will not be repeated here. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the code integration testing device and modules described above can be referred to the corresponding process descriptions in the aforementioned code integration testing method embodiments, and will not be repeated here.
[0080] Reference Figure 6 This shows a schematic diagram of the structure of an electronic device according to another embodiment of the present disclosure.
[0081] [P-137012-CN-PRI-1][HS2410875CCN] The specific embodiments do not limit the specific implementation of the electronic device.
[0082] like Figure 6 As shown, the electronic device may include: a processor 602 for executing program 610, a communications interface 604, a memory 606, and a communications bus 608.
[0083] The processor, communication interface, and memory communicate with each other via a communication bus.
[0084] A communication interface is used to communicate with other electronic devices or servers.
[0085] The processor is used to execute programs, specifically the relevant steps in the above method embodiments.
[0086] Specifically, the program may include program code, which includes computer operation instructions.
[0087] The processor may be a CPU, an Application Specific Integrated Circuit (ASIC), or one or more integrated circuits configured to implement embodiments of this disclosure. The smart device may include one or more processors of the same type, such as one or more CPUs; or it may include processors of different types, such as one or more CPUs and one or more ASICs.
[0088] Memory is used to store programs. Memory may include high-speed RAM, and may also include non-volatile memory, such as at least one disk drive.
[0089] The program may include multiple computer instructions, and specifically, the program may use multiple computer instructions to cause the processor to execute the various code integration test methods described in any of the foregoing method embodiments.
[0090] The specific implementation of each step in the program can be found in the corresponding descriptions of the steps, modules, or units in the above method embodiments, and has corresponding beneficial effects, which will not be repeated here. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the above-described device, equipment, or module can be referred to the corresponding process descriptions in the foregoing method embodiments, and will not be repeated here.
[0091] This disclosure also provides a computer storage medium storing a computer program thereon, which, when executed by a processor, implements the methods described in any of the foregoing method embodiments. The computer storage medium includes, but is not limited to, compact disc read-only memory (CD-ROM), random access memory (RAM), floppy disk, hard disk, or magneto-optical disk.
[0092] This disclosure also provides a computer program product, including computer instructions that instruct a computing device to execute various code integration test methods in the above-described multiple method embodiments.
[0093] Furthermore, it should be noted that the user-related information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to sample data used for training the model, data used for analysis, stored data, displayed data, etc.) involved in the embodiments of this disclosure are all information and data authorized by the user or fully authorized by all parties. Moreover, the collection, use and processing of related data must comply with relevant regulations and standards, and corresponding operation entry points are provided for users to choose to authorize or refuse.
[0094] It should be noted that, depending on the implementation needs, the various components / steps described in the embodiments of this disclosure can be broken down into more components / steps, or two or more components / steps or parts of the operation of components / steps can be combined into new components / steps to achieve the purpose of the embodiments of this disclosure.
[0095] [P-137012-CN-PRI-1][HS2410875CCN]
[0096] The methods described above according to embodiments of this disclosure can be implemented in hardware, firmware, or as software or computer code that can be stored in a recording medium (such as a CD-ROM, RAM, floppy disk, hard disk, or magneto-optical disk), or as computer code originally stored on a remote recording medium or a non-transitory machine-readable medium and subsequently stored on a local recording medium, downloaded over a network. Thus, the methods described herein can be stored on a recording medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware (such as an Application Specific Integrated Circuit (ASIC) or a Field Programmable Gate Array (FPGA)). It is understood that the computer, processor, microprocessor controller, or programmable hardware includes storage components (e.g., Random Access Memory (RAM), Read-Only Memory (ROM), Flash Memory, etc.) capable of storing or receiving software or computer code, which, when accessed and executed by the computer, processor, or hardware, implements the methods described herein. Furthermore, when a general-purpose computer accesses code used to implement the methods shown herein, the execution of the code transforms the general-purpose computer into a dedicated computer for performing the methods shown herein.
[0097] Those skilled in the art will recognize that the units and method steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the embodiments disclosed herein.
[0098] The above embodiments are only used to illustrate the embodiments of this disclosure, and are not intended to limit the embodiments of this disclosure. Those skilled in the art can make various changes and modifications without departing from the spirit and scope of the embodiments of this disclosure. Therefore, all equivalent technical solutions also fall within the scope of the embodiments of this disclosure, and the patent protection scope of the embodiments of this disclosure should be defined by the claims.
Claims
1. A code integration testing method, comprising: Feedback on operation events related to pushing updated branch code of development functional modules from the code hosting server; Based on the operation event feedback, perform a merge check to merge the updated branch code into the target branch code of the development function module; When the merge check result indicates that the check has passed, the code hosting terminal is notified to merge the updated branch code into the target branch code; The merged target branch code is obtained from the code hosting terminal, and dynamic functional testing is performed on the merged target branch code.
2. The code integration testing method according to claim 1, wherein, Based on the operation event feedback, perform a merge check to merge the updated branch code into the target branch code of the development function module, including: Based on the operation event feedback, a merge check request for the updated branch code is sent to the development end that pushed the updated branch code, and the merge check result is received from the development end. The merge check request instructs the development end to merge the updated branch code into the merge check of the target branch code.
3. The code integration testing method according to claim 1, wherein, Based on the operation event feedback, perform a merge check to merge the updated branch code into the target branch code of the development function module, including: Based on the operation event feedback, determine whether the updated branch code and the target branch code meet the static code check conditions; When the updated branch code and the target branch code meet the static code check conditions, a static code check is performed to merge the updated branch code into the target branch code of the development function module.
4. The code integration testing method according to claim 3, wherein, Based on the operation event feedback, performing a merge check to merge the updated branch code into the target branch code of the development function module further includes: When the updated branch code is the development branch code and the target branch code is the main branch code of the development function module, it is determined that the static code check condition is met.
5. The code integration testing method according to claim 4, wherein, Based on the operation event feedback, performing a merge check to merge the updated branch code into the target branch code of the development function module further includes: When the target branch code is not the main branch code of the development function module, the result of the merge check is directly determined as a pass.
6. The code integration testing method according to claim 5, wherein, Based on the operation event feedback, performing a merge check to merge the updated branch code into the target branch code of the development function module further includes: When the updated branch code is not the development branch code, the merge check result is directly determined as a failed check, and a close operation request is sent to the code hosting terminal based on the operation event feedback.
7. The code integration testing method according to claim 1, wherein, Perform dynamic functional testing on the merged target branch code, including: Obtain regression test cases for the merged target branch code, wherein the regression test cases include test input data related to the development function module code; The test input data is input into the merged target branch code to obtain the result of the dynamic function test.
8. The code integration testing method according to claim 7, wherein, Dynamic functional testing of the merged target branch code also includes: When the result of the dynamic function test indicates that the test has passed, a shutdown operation request for the operation event feedback is sent to the code hosting terminal.
9. The code integration testing method according to claim 1, wherein, Retrieve the merged target branch code from the code hosting provider, including: Monitor the merging operation of the updated branch code into the target branch code on the code hosting terminal; Obtain the target branch code merged through the merge operation from the code hosting terminal.
10. A code integration testing apparatus, comprising: The module retrieves operation event feedback for pushing updated branch code of the development function module from the code hosting end; The inspection module, based on the operation event feedback, performs a merge check to merge the updated branch code into the target branch code of the development function module; The notification module, when the merge check result indicates that the check has passed, notifies the code hosting end to merge the updated branch code into the target branch code; The testing module retrieves the merged target branch code from the code hosting terminal and performs dynamic functional testing on the merged target branch code.
11. A code integration testing system, comprising: Code hosting platform; The code integration testing apparatus according to claim 10.
12. An electronic device, comprising: The processor, memory, communication interface, and communication bus are provided, wherein the processor, memory, and communication interface communicate with each other via the communication bus. The memory is used to store at least one executable instruction that causes the processor to perform the method according to any one of claims 1-9.
13. A computer storage medium having a computer program stored thereon, which, when executed by a processor, implements the method according to any one of claims 1-9.
14. A computer program product comprising computer instructions that, when executed by a processor, implement the method of any one of claims 1-9.