How to do batch testing in the banking system~

guide

At present, in the application processing mode of the computer mainframe, batch processing, as a post-event data processing method, has always been a simple and very important processing method, especially for massive data processing, the batch method can show its high efficiency. processing effect. As batch transactions become more and more complex and the timeliness of batch processing is required, there is an urgent need for an effective and fast batch job testing method to realize automated testing of batch processing.

 

batch processing

Batch processing refers to the process of completing a large amount of data access, calculation, classification, analysis, and summary of data in a batch mode, and finally outputs a large number of business analysis reports, showing a large amount of data access, large amount of calculation, and complicated processes. characteristic.

Generally speaking, batch processing is executed by establishing a job plan template, which is executed manually or automatically by the system. The template contains a number of nodes arranged according to the order of business logic processing, and the nodes can call up the corresponding batch transaction program. Process the data and output the result.

At present, a large amount of data processing in banks is performed in batches, covering multiple business lines such as accounting, corporate business, personal business, credit card business, customer information business, data processing business, etc., involving account processing, report statistics, For multiple core functions such as data processing and consumption, how to effectively check, verify and ensure the correctness of batch business has become a key task for the bank's testing department.

  

Common concerns of batch transaction testing

Although there are many types of bank batch business, the focus of the testing process is basically the following:

1. Pay attention to the batch job chain configuration, such as: the correctness of the configuration template, whether the scheduling plan meets expectations, whether the agent can normally call the program, whether the load balancing strategy is effective, etc.

2. The correctness of batch program logic processing, including whether the processing logic is correct, whether there are data omissions, whether there is duplication, the structure of the storage table, field names, special characters, whether super long characters can be stored normally, etc.

3. The correctness of the grammar and format of the program itself, such as whether it contains plaintext passwords, whether exception handling is included, whether the log classification is correct, whether there are log records for key steps, whether the program grammar is standardized, and whether special parameters can be handled correctly, etc.

4. Whether the performance efficiency meets the requirements. Batch transactions are often interlocking, and the results of upstream processing are often the input of downstream processing. Therefore, batch scripts must be completed within a certain period of time.
 

Manual batch test method

Based on the above test points, the general steps for manual testing are: design test cases according to requirements, prepare test data to insert positive and negative test data, execute batch programs, query databases, and write check statements to check generated data according to expected results.

However, manual testing often has the following limitations:

The test efficiency is low. In the actual test process, it is necessary to apply for various permissions and then connect to the loader and database. Manually repeat operations one by one, the test efficiency is low, and it cannot effectively support regression tests with rigid time requirements

Test assets cannot be accumulated effectively. The SQL statement used in the test process, the written test program, etc. cannot be managed and reused in a structured manner

Batch testing places high demands on testers. For batch programs with complex logic, multiple data sources, and large data volumes, it is difficult to write and check SQL statements or programs

Difficult to monitor quality. There are many co-organized projects in batches, and the logic coupling between upstream and downstream is tight. Manual testing leads to scattered test distribution, which makes effective monitoring impossible.
 

Preliminary Discussion on Batch Test Platform

In response to the above problems, our team developed a batch testing platform, which realized the whole-process automated testing from data preparation->batch execution->result verification.

The core functions of the platform are:

1. Connect the entire testing process through the batch platform to perform automated testing and provide support for regression testing.

2. Manage the entered test assets to facilitate subsequent reuse and reference

3. Through a series of preset inspection rules: table structure inspection, data volume inspection, data null value inspection, data legality inspection, and data correctness inspection, the threshold for data inspection by testers is lowered, and at the same time, it supports inter-database, file Compared with databases and large data volumes between files.

4. Save the multi-period test data, and conduct quality analysis from multiple dimensions such as project and system.

The basic process of platform testing:

basic process

The platform is mainly divided into three modules, configuration management, execution management, and statistical analysis. Configuration management is mainly for entering basic information. The subsequent platform will use these information to connect to the database and loader, and then enter system information and project information. This step is convenient and separate Classify test assets from system and project dimensions.

Configuring database
execution management is the core of configuring test strategies. How to prepare test data, execute specific commands for batch programs, and configure the inspection methods for execution results. Here we preset some common inspection rules to support basic result inspections, such as data volume. For comparison, whether the data field type meets expectations, whether a certain field is within the expected range, whether the two tables or the data in the table and the file are consistent, etc. Through these well-defined comparison rules, the threshold for writing and checking SQL statements is lowered, and the complicated manual checking process is avoided.

Batch management of configuration test files
is to organize tasks. Here we use tasks as the smallest unit of execution. A batch can contain multiple tasks, because in the actual testing process, a project may contain multiple batch test tasks. The execution environments and systems of these test tasks are different, but they all belong to the same project, so the concept of batches is used here to arrange multiple tasks.

Batch management
execution history Here you can view the result report. We match each sheet page configured in excel one by one here, and you can see the specific execution log, the statement with the wrong result, and extract a certain amount of error data to For defect analysis.

The statistical analysis module of the test results
has not yet been developed. In the future, according to the usage situation, after accumulating enough data, different reports and statistical methods will be adopted for the data collection, in order to continuously monitor the quality of batch programs through data analysis and report presentation. Tracking, thereby improving the quality of testing.

Summarize

Batch testing has no foreground page, complex logical relationships, many business areas covered, and large data volume, which makes batch testing very difficult. Even though the generation of the platform can solve the automation and reduce the difficulty of some inspections, the complexity of its number creation and testing still exists, resulting in complex platform configuration. As Xunzi said, "If you keep walking, you can go a thousand miles; if you don't accumulate, you can become a rich man." The next step is to combine more new technologies with the actual project, dismantle its complexity step by step, and further increase the batch size. Test efficiency.

Finally, I would like to thank everyone who has read my article carefully. Reciprocity is always necessary. Although it is not a very valuable thing, you can take it away if you need it:

These materials should be the most comprehensive and complete preparation warehouse for [software testing] friends. This warehouse has also accompanied tens of  thousands of test engineers through the most difficult journey, and I hope it can help you! Partners can click the small card below to receive 

Guess you like

Origin blog.csdn.net/qq_48811377/article/details/131834468