A business system testing method and device
The data of the second business system is applied to the first business system test through the business mapping relationship, which solves the problem that manual writing of data cannot cover the real scenario, and improves the accuracy and efficiency of the test.
Patent Information
- Application Number
- CN202011582317.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-28
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2040-12-28
AI Technical Summary
In the prior art, technicians cannot fully cover real usage scenarios by manually writing test data, resulting in low accuracy and efficiency of system testing.
By determining the business type of the business system to be tested, using the business mapping relationship to use the business data of the second business system as test data, covering more real scenarios, and achieving comprehensive testing of the first business system.
No need to manually write test data, which improves the accuracy and efficiency of the test and allows more complete testing of business systems.
Smart Images

Figure CN112579468B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a testing method and device for a business system. Background Art
[0002] Testing is a very important step in the system development process. Technicians often need to manually write a large amount of test data for the developed system and simulate usage scenarios to test the relevant functions of the system.
[0003] In the process of implementing the present invention, the inventors found that there are at least the following problems in the prior art:
[0004] Due to the technicians' own preferences or abilities, the test data manually written by the technicians cannot fully cover the actual usage scenarios, resulting in the inability to conduct comprehensive testing of the relevant functions of the developed system, which in turn leads to low test accuracy and efficiency. Summary of the invention
[0005] In view of this, an embodiment of the present invention provides a testing method and device for a business system. After determining a first business type corresponding to a first business system to be tested, the first business system can be tested by using business data of a second business type corresponding to the first business type run by a second business system according to a business mapping relationship as test data. This eliminates the need for technical personnel to manually write test data, and uses business data obtained from the operation of an existing second business system as test data, which can also cover more real usage scenarios, thereby enabling a more complete test of the first business system and improving the accuracy and efficiency of the test.
[0006] To achieve the above objective, according to one aspect of an embodiment of the present invention, a method for testing a business system is provided.
[0007] A method for testing a business system according to an embodiment of the present invention includes:
[0008] Determine a first service type corresponding to a first service system to be tested;
[0009] Determine, according to the service mapping relationship, a second service type corresponding to the first service type;
[0010] Determine business data of a second business type running in a second business system, and use the business data as test data;
[0011] The first business system is tested using the test data.
[0012] Optionally,
[0013] Determining the business data of the second business type running in the second business system includes:
[0014] Determining message data of the second business system;
[0015] The service data corresponding to the second service type is extracted from the message data.
[0016] Optionally,
[0017] Business data includes data labels and business values. Business data is used as test data, including:
[0018] For each first service type, execute:
[0019] Determine a first data tag corresponding to the first service type, and the extracted target service data corresponding to the first service type;
[0020] According to the first data tag, determining from the target business data a second data tag corresponding to the first data tag and a second business value corresponding to the second data tag;
[0021] The second service value is used as test data corresponding to the first data label.
[0022] Optionally,
[0023] According to a preset error range table, a first data tag to be tested is determined; wherein the allowable error range of the first data tag to be tested is greater than a preset threshold; the error range table includes: one or more data tags, and an allowable error range corresponding to each data tag;
[0024] A second data tag corresponding to the first data tag to be tested and a second service value corresponding to the second data tag are determined from the target service data.
[0025] Optionally,
[0026] Determining a second data tag corresponding to the first data tag from the target business data includes:
[0027] Determining a plurality of second data tags included in the target business data;
[0028] The plurality of second data tags are traversed to find a second data tag corresponding to the first data tag.
[0029] Optionally,
[0030] When the character string corresponding to the second data tag is included in the character string corresponding to the first data tag, it is determined that the second data tag corresponds to the first data tag.
[0031] Optionally,
[0032] According to a preset tag correspondence table, a second data tag corresponding to the first data tag is determined from the target business data.
[0033] Optionally,
[0034] Use business data as test data, including:
[0035] Determining a first data type required by a first business system;
[0036] Determine a second data type of the business data;
[0037] Determine whether the first data type and the second data type are the same; if not, convert the business data according to the first data type, and use the converted business data as test data.
[0038] Optionally,
[0039] According to the first data type, the business data is converted, including:
[0040] Constructing a decoding mapping table; wherein the decoding mapping table includes: multiple data types, multiple characters included in each of the multiple data types, and character correspondences between different data types;
[0041] The service data is converted according to the decoding mapping table.
[0042] Optionally,
[0043] According to the decoding mapping table, the service data is converted, including:
[0044] Determine a second data type corresponding to the service data from the decoding mapping table, and determine a plurality of characters to be converted included in the service data from a plurality of characters corresponding to the second data type;
[0045] Determine a plurality of characters corresponding to the first data type in the decoding mapping table;
[0046] According to the character correspondence between the first data type and the second data type in the decoding mapping table, a target character corresponding to each character to be converted is determined among multiple characters corresponding to the first data type to convert the service data.
[0047] Optionally,
[0048] The first business system and the second business system are financial transaction systems;
[0049] The first business type includes any one or more of the following: contract-level accounting, channel outreach accounting, cash flow accounting, and detailed accounting.
[0050] Optionally,
[0051] When the first business type is contract-level account tracking,
[0052] Use test data to test foreign exchange transactions and borrowing transactions.
[0053] Optionally,
[0054] The first data tag corresponding to the foreign exchange transaction includes any one or more of the following: the product type, transaction date, expiration and delivery, counterparty abbreviation, transaction currency pair, transaction direction, currency, amount corresponding to the currency, payment date, pricing exchange rate and non-deliverable forward foreign exchange transaction interest rate fixing date corresponding to the foreign exchange transaction;
[0055] and / or,
[0056] The first data tag corresponding to the repo transaction includes any one or more of the following: the product type corresponding to the repo transaction, transaction date, interest accrual date, maturity date, counterparty abbreviation, currency code, transaction amount, maturity repayment amount, interest, interest rate type, fixed interest rate value, fixed interest calculation rules, floating interest rate benchmark, interest spread, floating interest calculation rules, interest calculation method, reset frequency, reset holidays, reset period, payment holidays, payment holiday rules, interest calculation frequency, interest calculation adjustment method, interest calculation calendar, and interest settlement method.
[0057] Optionally,
[0058] When the first business type is channel outreach and account tracking,
[0059] The first data tag includes any one or more of the following: clearing currency code, actual clearing amount, sending bank number, receiving bank number, payee account name, payee account number, payee account opening bank number, payee account opening bank name, beneficiary bank number, payee account name, beneficiary address, beneficiary account number, beneficiary account opening bank number, and beneficiary account opening bank name.
[0060] Optionally,
[0061] When the first business type is cash flow tracking,
[0062] The first data tag includes any one or more of the following: the business type corresponding to the cash flow, the short name of the counterparty, the clearing currency code, the custom name of the remittance path, and the clearing path category code.
[0063] Optionally,
[0064] When the first business type is detailed account tracking,
[0065] The first data tag includes any one or more of the following: accounting date, product contract number, transaction institution number, account institution number, multi-entity identifier, currency code, account direction code, natural account number, off-balance sheet account mark, detailed entry transaction amount, account responsibility center number, public customer type code, correspondent institution number, and general ledger term code.
[0066] To achieve the above objective, according to another aspect of an embodiment of the present invention, a testing device for a business system is provided.
[0067] A testing device for a business system according to an embodiment of the present invention comprises a first type confirmation module, a second type confirmation module, a test data determination module and a test module; wherein:
[0068] A first type confirmation module, used to determine a first business type corresponding to a first business system to be tested;
[0069] A second type confirmation module, used to determine a second service type corresponding to the first service type according to the service mapping relationship;
[0070] A test data determination module, used to determine business data of a second business type running in a second business system, and use the business data as test data;
[0071] The test module is used to test the first business system using test data.
[0072] To achieve the above objective, according to another aspect of an embodiment of the present invention, a test electronic device for a business system is provided.
[0073] A testing electronic device for a business system according to an embodiment of the present invention comprises: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by one or more processors, the one or more processors implement a testing method for a business system according to an embodiment of the present invention.
[0074] To achieve the above objective, according to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided.
[0075] A computer-readable storage medium according to an embodiment of the present invention stores a computer program, and when the program is executed by a processor, a business system testing method according to an embodiment of the present invention is implemented.
[0076] An embodiment of the above invention has the following advantages or beneficial effects: after determining the first business type corresponding to the first business system to be tested, the business data of the second business type corresponding to the first business type run by the second business system can be used as test data according to the business mapping relationship to test the first business system, thereby eliminating the need for technical personnel to manually write test data, and using the business data obtained from the operation of the existing second business system as test data, it can also cover more real usage scenarios, thereby being able to more completely test the first business system and improve the accuracy and efficiency of the test.
[0077] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0078] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0079] Figure 1 is a schematic diagram of main steps of a method for testing a business system according to an embodiment of the present invention;
[0080] Figure 2 is a schematic diagram of main steps of a method for using business data as test data according to an embodiment of the present invention;
[0081] Figure 3 is an example diagram of a first data label corresponding to a foreign exchange transaction of a first business system according to an embodiment of the present invention;
[0082] Figure 4 is an example diagram of a first data label corresponding to a lending transaction of a first business system according to an embodiment of the present invention;
[0083] Figure 5 is a schematic diagram of main steps of a method for converting business data according to an embodiment of the present invention;
[0084] Figure 6 It is a schematic diagram of a rule for extracting message data from a SWIFT channel according to an embodiment of the present invention;
[0085] Figure 7 is a schematic diagram of a rule for matching message data of a second service system with a first service system according to an embodiment of the present invention;
[0086] Figure 8 is a screenshot of obtaining test data from message data to perform a comparison test on the first business system;
[0087] Fig. 9is a schematic diagram of a rule for extracting message data from a CNAPS channel according to an embodiment of the present invention;
[0088] Fig.10 is an example diagram of a first data label corresponding to a first business system according to an embodiment of the present invention;
[0089] Fig.11 is an example diagram of a first data label corresponding to another first business system according to an embodiment of the present invention;
[0090] Fig.12 is a schematic diagram of a rule for obtaining business data according to an embodiment of the present invention;
[0091] Fig.13 is an example diagram of a first data label corresponding to another first business system according to an embodiment of the present invention;
[0092] Fig.14 is a schematic diagram of main modules of a testing device for a business system according to an embodiment of the present invention;
[0093] Fig.15 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0094] Fig.16 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION
[0095] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0096] It should be pointed out that the embodiments of the present invention and the technical features therein may be combined with each other without conflict.
[0097] Figure 1 It is a schematic diagram of main steps of a method for testing a business system according to an embodiment of the present invention.
[0098] like Figure 1 As shown, a testing method of a business system in an embodiment of the present invention mainly includes the following steps:
[0099] Step S101: Determine a first service type corresponding to a first service system to be tested.
[0100] In an embodiment of the present invention, the first business system is a financial transaction system. In a preferred embodiment of the present invention, the first business system is a capital transaction operation platform system.
[0101] In the embodiment of the present invention, the first business type includes any one or more of the following: contract-level tracking, channel external tracking, cash flow tracking, and detailed accounting. The goal of testing the first business type is to automatically compare and analyze the full volume of transactions in one or more days in the background processing links such as transaction confirmation, transaction clearing and settlement, and transaction accounting of the first business system at the contract level (small tracking), external channel message level (large tracking), cash flow level, and accounting level (accounting tracking) to verify whether the processing results of the first business system at these four levels meet expectations.
[0102] Step S102: Determine a second service type corresponding to the first service type according to the service mapping relationship.
[0103] In an embodiment of the present invention, a business mapping relationship between a first business type of a first business system and a second business type of a second business system can be preconfigured, so that after determining the first business type corresponding to the first business system to be tested, the second business type corresponding to the first business type to be tested can be determined according to the business mapping relationship. In a preferred embodiment of the present invention, the business mapping relationship is stored in a business number mapping table.
[0104] Step S103: Determine business data of a second business type running in the second business system, and use the business data as test data.
[0105] In an embodiment of the present invention, the first business system and the second business system are financial transaction systems. In a preferred embodiment of the present invention, the first business system is a fund transaction operation platform system, and the second business system is an Opics operation platform system.
[0106] In the embodiment of the present invention, the business data may include data tags and business values. In this case, a method of using the business data as test data is as follows: Figure 2 As shown, the method performs the following steps for each first service type:
[0107] Step S201: determining a first data tag corresponding to a first service type, and extracting target service data corresponding to the first service type;
[0108] Step S202: According to the first data tag, determine from the target business data a second data tag corresponding to the first data tag and a second business value corresponding to the second data tag;
[0109] Step S203: Use the second service value as test data corresponding to the first data tag.
[0110] In an embodiment of the present invention, when determining a second data tag corresponding to a first data tag from target business data, multiple second data tags included in the target business data may be determined first, and then multiple second data tags may be traversed to find the second data tag corresponding to the first data tag. Specifically, when the string corresponding to the second data tag is included in the string corresponding to the first data tag, it may be determined that the second data tag corresponds to the first data tag; or the second data tag corresponding to the first data tag may be determined from the target business data according to a preset tag correspondence table.
[0111] In the embodiment of the present invention, the first data label and the second data label that need to be compared during the test can be distinguished and identified according to the dimensions of major categories and minor categories of the product.
[0112] In the embodiment of the present invention, the first business type includes any one or more of the following: contract-level account tracking, channel external account tracking, cash flow account tracking, and detailed account tracking.
[0113] In the embodiment of the present invention, when the first business type is contract-level account tracking, the test data can be used to test foreign exchange transactions and borrowing transactions.
[0114] When testing foreign exchange transactions using test data, the first data label corresponding to the foreign exchange transactions may include, but is not limited to, any one or more of the following: the product type, transaction date, expiration and delivery, counterparty abbreviation, transaction currency pair, transaction direction, currency, amount corresponding to the currency, payment date, pricing exchange rate, and fixed interest date of non-deliverable forward foreign exchange transactions corresponding to the foreign exchange transactions.
[0115] For example, if Figure 3 As shown, Figure 3 It is a first business system (i.e. Figure 3 The first data label is the field name under the "Blue Core System Data" column, and the second data label is the field under the "Opics System Data" column. Figure 3 The first data label and the second data label corresponding to the foreign exchange transaction in the include: the product type corresponding to the foreign exchange transaction (including the background major product category and the background minor product category), transaction date, maturity delivery, counterparty abbreviation, transaction currency pair, transaction direction, currency (including currency one code and currency two code), amount corresponding to currency (including currency one near-end amount, currency one far-end amount, currency two near-end amount, currency two far-end amount), payment date (including near-end payment date and far-end payment date), pricing exchange rate and non-deliverable forward foreign exchange transaction NDF fixed interest date.
[0116] When testing a repo transaction using test data, the first data label corresponding to the repo transaction may include but is not limited to any one or more of the following: the product type corresponding to the repo transaction, transaction date, interest accrual date, maturity date, counterparty abbreviation, currency code, transaction amount, maturity repayment amount, interest, interest rate type, fixed interest rate value, fixed interest calculation rules, floating interest rate benchmark, interest spread, floating interest calculation rules, interest calculation method, reset frequency, reset holidays, reset period, payment holidays, payment holiday rules, interest calculation frequency, interest calculation adjustment method, interest calculation calendar and interest settlement method.
[0117] For example, if Figure 4 As shown, Figure 4 It is a first business system (i.e. Figure 4 The first data label is the Chinese characters and / or field names of the fields under the "Blue Core System Data" column, and the second data label is the fields under the "Opics System Data" column. Figure 4 The first data label and the second data label corresponding to the borrowing and lending transaction in the include: the product type corresponding to the borrowing and lending transaction (including the background major product category and the background minor product category), transaction date, interest accrual date, maturity date, counterparty abbreviation, currency code, transaction amount, maturity repayment amount, interest, interest rate type, fixed interest rate value, fixed interest calculation rules, floating interest rate benchmark, interest spread, floating interest calculation rules, interest calculation method, reset frequency, reset holidays, reset period, payment holidays, payment holiday rules, interest calculation frequency, interest calculation adjustment method, interest calculation calendar and interest settlement method.
[0118] exist Figure 3 and Figure 4 In the "Comparison Method" column, it can be seen that there are "Direct Comparison", "Decoding Comparison" and "Complex Comparison". Among them, "Direct Comparison" means that the first data type required by the first business system and the second data type of the business data are consistent, and the comparison test can be directly performed; "Decoding Comparison" means that the first data type and the second data type are inconsistent, and the business data needs to be converted so that the business data can be recognized by the first business system; "Complex Logic" is an extremely rare special case, and the business data of different second business types need to be processed separately in a targeted manner so that the processed business data can be used as test data for the first business system.
[0119] Therefore, in an embodiment of the present invention, for business data that is not "complex logic", before using it as test data, it is necessary to first determine the first data type required by the first business system and the second data type of the business data, and then determine whether the first data type and the second data type are the same: if not, convert the business data according to the first data type, and use the converted business data as test data; if yes, directly use the business data as test data.
[0120] In an embodiment of the present invention, a method for converting business data is as follows: Figure 5 As shown, the method mainly includes the following steps:
[0121] Step S501: constructing a decoding mapping table; wherein the decoding mapping table includes: multiple data types, multiple characters included in each of the multiple data types, and character correspondences between different data types;
[0122] Step S502: determining a second data type corresponding to the service data from the decoding mapping table, and determining a plurality of characters to be converted included in the service data from a plurality of characters corresponding to the second data type;
[0123] Step S503: determining a plurality of characters corresponding to the first data type in the decoding mapping table;
[0124] Step S504: According to the character correspondence between the first data type and the second data type in the decoding mapping table, a target character corresponding to each character to be converted is determined among multiple characters corresponding to the first data type to convert the service data.
[0125] In an embodiment of the present invention, when the first business type is channel external connection and account tracking, the first business system needs to send out messages. The messages sent out by the first business system can be divided into confirmation messages and payment messages according to functional classification. Among them, the confirmation messages of the SWIFT channel are divided into MT300 and MT320 messages due to the difference between foreign exchange and interbank lending products, and the payment messages of the SWIFT channel are divided into MT202 and MT210 messages due to the different payment and collection directions. In addition to the SWIFT channel, the payment message can also include the CNAPS channel, which is dedicated to large-value RMB payment and collection messages. Among them, only the payment message of the CNAPS channel will be sent out.
[0126] In the embodiment of the present invention, when determining the service data, the message data of the second service system may be determined first, and then the service data corresponding to the second service type may be extracted from the message data.
[0127] Specifically, for the SWIFT channel, the message data extraction rules are as follows: Figure 6As shown, the rule for matching the message data of the second business system with the first business system is as follows Figure 7 After matching, the service data corresponding to the second service type can be extracted from the message data to test the first service system.
[0128] For example, if Figure 8 As shown, Figure 8 This is a screenshot of obtaining test data from message data to perform a comparison test on the first business system. The business value corresponding to the first data tag 32A circled in the Opics system M202 message is used as test data to perform a comparison test on the second data tag tagKey32A circled in the "Blue Core" system M202 message; and the business value corresponding to the first data tag 22C circled in the 15A field in the Opics system M300 message is used as test data to perform a comparison test on the second data tag tagKey15A.22C circled in the "Blue Core" system M300 message.
[0129] For CNAPS channels, the rules for extracting message data are as follows: Fig. 9 At this time, the first data tag may include but is not limited to any one or more of the following: clearing currency code, actual clearing amount, sending bank number, receiving bank number, payee account name, payee account number, payee account opening bank number, payee account opening bank name, receiving bank number, payee account name, payee address, payee account number, payee account opening bank number, and payee account opening bank name.
[0130] For example, if Fig.10 As shown, Fig.10 It is a first business system (i.e. Fig.10 The first data label is the field and / or new generation definition under the "Blue Core System Data" column, and the second data label is the field under the "Fund Transaction Background Data" column. Fig.10 The first data label and the second data label in the include: clearing currency code, actual clearing amount, sending bank number, receiving bank number, payee account name, payee account number, payee account opening bank number, payee account opening bank name, beneficiary bank number, payee account name, beneficiary address, beneficiary account number, beneficiary account opening bank number, and beneficiary account opening bank name.
[0131] In an embodiment of the present invention, when the first business type is cash flow tracking, the first data tag may include but is not limited to any one or more of the following: the business type corresponding to the cash flow, the counterparty short name, the clearing currency code, the remittance path custom name, and the clearing path category code.
[0132] For example, if Fig.11As shown, Fig.11 This is another example of the first data label corresponding to the first business system. The first data label is the BlueCore plan cash flow comparison field and / or the Chinese description of the cash flow comparison field, and the second data label is Opics or the corresponding system comparison field and / or Opics or the Chinese description of the corresponding system comparison field. Fig.11 The first data label and the second data label in are not consistent. The first data label and the second data label both include: transaction number, cash flow number, business type corresponding to the cash flow (including major business categories and minor business categories), payment date, counterparty number, counterparty short name, clearing currency code, clearing path category code, clearing account short name, remittance path custom name and cash flow interval type.
[0133] In the embodiment of the present invention, when the first business type is a detailed account, the rule for obtaining business data is as follows: Fig.12 At this time, the first data tag may include, but is not limited to, any one or more of the following: accounting date, product contract number, transaction institution number, account institution number, multi-entity identifier, currency code, account direction code, natural account number, off-balance sheet account mark, detailed entry transaction amount, account responsibility center number, public customer type code, transaction institution number, and general ledger term code.
[0134] In an embodiment of the present invention, a first data tag to be tested is determined according to a preset error range table; wherein the allowable error range of the first data tag to be tested is greater than a preset threshold; the error range table includes: one or more data tags, and the allowable error range corresponding to each data tag; a second data tag corresponding to the first data tag to be tested and a second business value corresponding to the second data tag are determined from the target business data.
[0135] For example, if Fig.13 As shown, Fig.13 It is another first business system (i.e. Fig.13 The first data label is the field and / or new generation definition under the "Blue Core System Data" column, and the second data label is the field under the "Opics System Data Provided File" column. Fig.13 The first data tag and the second data tag in the include: accounting date, product contract number, transaction institution number, account institution number, multi-entity identifier, currency code, account direction code, natural account number, off-balance sheet account mark, detailed entry transaction amount, account responsibility center number, public customer type code, intra-group transaction institution number, and general ledger term code.
[0136] Step S104: Testing the first business system using test data.
[0137] In an embodiment of the present invention, after the test data is determined, the test data can be used to test the first business system. In a preferred embodiment of the present invention, the test sequence is:
[0138] First, we will conduct contract-level account tracking tests, which are expected to start when the second round of application assembly tests begins. The FTB platform functions are relatively stable.
[0139] Secondly, conduct channel external connection and account tracking test, which is expected to start in the middle and late stages of contract-level account tracking test, and when the collaborative payment settlement components and external connections are relatively stable;
[0140] Then, conduct cash flow tracking test on the transaction. The expected start time is in the middle and late stages of contract-level tracking test, which can be conducted simultaneously with channel external tracking test.
[0141] Finally, the total accounting and detailed account testing is carried out. The estimated start time is the second round of user testing, the middle and late stages of the accounting special testing, that is, the middle and late stages of the household account function testing.
[0142] For example, during the test, you can Figure 3 , Figure 4 , Fig.10 , Fig.11 ,or Fig.13 The “Comparison Logic” in the example uses the test data to perform a comparison test on the first business system.
[0143] In the embodiment of the present invention, when the first business system is tested using test data, problems that occur during the test, tracking of problems and circulation can be managed in a unified manner, and the test problems can be assigned to personnel in the next link. If the tester finds a test problem during the execution process, the test problem should be registered in time, the problem should be tracked and analyzed, the solution process should be repeated in time, and the problem status should be set to the final status, and the developer should analyze and handle the defect in time, and record the analysis and processing information of the defect as required.
[0144] It can be seen from a testing method for a business system according to an embodiment of the present invention that after determining the first business type corresponding to the first business system to be tested, the business data of the second business type corresponding to the first business type run by the second business system can be used as test data according to the business mapping relationship to test the first business system, thereby eliminating the need for technical personnel to manually write test data, and using the business data obtained from the operation of the existing second business system as test data can also cover more real usage scenarios, thereby being able to more completely test the first business system and improve the accuracy and efficiency of the test.
[0145] Fig.14 It is a schematic diagram of main modules of a testing device for a business system according to an embodiment of the present invention.
[0146] like Fig.14 As shown, a testing device 1400 for a business system according to an embodiment of the present invention includes a first type confirmation module 1401, a second type confirmation module 1402, a test data determination module 1403 and a test module 1404; wherein:
[0147] A first type confirmation module 1401 is used to determine a first service type corresponding to a first service system to be tested;
[0148] A second type confirmation module 1402 is used to determine a second service type corresponding to the first service type according to the service mapping relationship;
[0149] A test data determination module 1403 is used to determine business data of a second business type running in the second business system, and use the business data as test data;
[0150] The testing module 1404 is used to test the first business system using the test data.
[0151] In the embodiment of the present invention, the test data determination module 1403 is further used to: determine the message data of the second service system; and extract the service data corresponding to the second service type from the message data.
[0152] In an embodiment of the present invention, business data includes data tags and business values, and the test data determination module 1403 is further used to: for each first business type, execute: determine the first data tag corresponding to the first business type, and the extracted target business data corresponding to the first business type; based on the first data tag, determine the second data tag corresponding to the first data tag and the second business value corresponding to the second data tag from the target business data; use the second business value as the test data corresponding to the first data tag.
[0153] In an embodiment of the present invention, the test data determination module 1403 is further used to: determine the first data tag to be tested according to a preset error range table; wherein the allowable error range of the first data tag to be tested is greater than a preset threshold; the error range table includes: one or more data tags, and the allowable error range corresponding to each data tag; determine the second data tag corresponding to the first data tag to be tested and the second business value corresponding to the second data tag from the target business data.
[0154] In the embodiment of the present invention, the test data determination module 1403 is further used to: determine a plurality of second data tags included in the target business data; and traverse the plurality of second data tags to find a second data tag corresponding to the first data tag.
[0155] In the embodiment of the present invention, the test data determination module 1403 is further configured to: when the character string corresponding to the second data tag is included in the character string corresponding to the first data tag, determine that the second data tag corresponds to the first data tag.
[0156] In the embodiment of the present invention, the test data determination module 1403 is further used to determine a second data tag corresponding to the first data tag from the target business data according to a preset tag correspondence table.
[0157] In an embodiment of the present invention, the test data determination module 1403 is further used to: determine a first data type required by the first business system; determine a second data type of the business data; determine whether the first data type and the second data type are the same, and if not, convert the business data according to the first data type, and use the converted business data as test data.
[0158] In an embodiment of the present invention, the test data determination module 1403 is further used to: construct a decoding mapping table; wherein the decoding mapping table includes: multiple data types, multiple characters included in each of the multiple data types, and character correspondences between different data types; and convert business data according to the decoding mapping table.
[0159] In an embodiment of the present invention, the test data determination module 1403 is further used to: determine a second data type corresponding to the business data from a decoding mapping table, and determine a plurality of characters to be converted included in the business data among a plurality of characters corresponding to the second data type; determine a plurality of characters corresponding to the first data type in the decoding mapping table; and determine a target character corresponding to each character to be converted among a plurality of characters corresponding to the first data type according to the character correspondence relationship between the first data type and the second data type in the decoding mapping table, so as to convert the business data.
[0160] In an embodiment of the present invention, the first business system and the second business system are financial transaction systems; the first business type includes any one or more of the following: contract-level account tracking, channel external account tracking, cash flow account tracking, and detailed account tracking.
[0161] In the embodiment of the present invention, when the first business type is contract-level account tracking, the testing module 1404 is further used to: test foreign exchange transactions and borrowing transactions using test data.
[0162] In an embodiment of the present invention, the first data tag corresponding to the foreign exchange transaction includes any one or more of the following: the product type, transaction date, expiration and delivery, counterparty abbreviation, transaction currency pair, transaction direction, currency, amount corresponding to the currency, payment date, pricing exchange rate and non-deliverable forward foreign exchange transaction interest rate fixing date corresponding to the foreign exchange transaction; and / or,
[0163] The first data tag corresponding to the repo transaction includes any one or more of the following: the product type corresponding to the repo transaction, transaction date, interest accrual date, maturity date, counterparty abbreviation, currency code, transaction amount, maturity repayment amount, interest, interest rate type, fixed interest rate value, fixed interest calculation rules, floating interest rate benchmark, interest spread, floating interest calculation rules, interest calculation method, reset frequency, reset holidays, reset period, payment holidays, payment holiday rules, interest calculation frequency, interest calculation adjustment method, interest calculation calendar, and interest settlement method.
[0164] In an embodiment of the present invention, when the first business type is channel external liaison and account tracking, the first data tag includes any one or more of the following: clearing currency code, actual clearing amount, sending bank number, receiving bank number, payee account name, payee account number, payee account opening bank number, payee account opening bank name, beneficiary bank number, payee account name, payee address, payee account number, payee account opening bank number, and payee account opening bank name.
[0165] In an embodiment of the present invention, when the first business type is cash flow tracking, the first data tag includes any one or more of the following: the business type corresponding to the cash flow, the counterparty short name, the clearing currency code, the remittance path custom name, and the clearing path category code.
[0166] In an embodiment of the present invention, when the first business type is detailed account tracking, the first data tag includes any one or more of the following: accounting date, product contract number, transaction institution number, account institution number, multi-entity identifier, currency code, account occurrence direction code, natural account number, off-balance sheet account mark, detailed entry transaction amount, account responsibility center number, corporate customer type code, business institution number, and general ledger term code.
[0167] It can be seen from a testing device for a business system according to an embodiment of the present invention that after determining the first business type corresponding to the first business system to be tested, the business data of the second business type corresponding to the first business type run by the second business system can be used as test data according to the business mapping relationship to test the first business system, thereby eliminating the need for technical personnel to manually write test data, and using the business data obtained from the operation of the existing second business system as test data can also cover more real usage scenarios, thereby being able to more completely test the first business system and improve the accuracy and efficiency of the test.
[0168] Fig.15 An exemplary system architecture 1500 is shown to which a method for testing a business system or a device for testing a business system according to an embodiment of the present invention can be applied.
[0169] like Fig.15 As shown, system architecture 1500 may include terminal devices 1501, 1502, 1503, a network 1504, and an electronic device 1505. Network 1504 is used to provide a medium for communication links between terminal devices 1501, 1502, 1503 and electronic device 1505. Network 1504 may include various connection types, such as wired, wireless communication links, or optical fiber cables, etc.
[0170] The user can use the terminal devices 1501, 1502, 1503 to interact with the electronic device 1505 through the network 1504 to receive or send messages, etc. Various communication client applications can be installed on the terminal devices 1501, 1502, 1503, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0171] The terminal devices 1501 , 1502 , and 1503 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers, etc.
[0172] The electronic device 1505 may be a server that provides various services, such as a background management server that provides support for shopping websites browsed by users using the terminal devices 1501, 1502, and 1503. The background management server may analyze and process the received data such as product information query requests, and feed back the processing results (such as target push information and product information) to the terminal device.
[0173] It should be noted that the testing method for a business system provided in the embodiment of the present invention is generally executed by the electronic device 1505 , and accordingly, a testing device for a business system is generally disposed in the electronic device 1505 .
[0174] It should be understood that Fig.15 The number of terminal devices, networks and electronic devices in the embodiment is only for illustration. Any number of terminal devices, networks and electronic devices may be provided according to implementation requirements.
[0175] Reference below Fig.16 , which shows a schematic diagram of the structure of a computer system 1600 of a terminal device suitable for implementing an embodiment of the present invention. Fig.16The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0176] like Fig.16 As shown, the computer system 1600 includes a central processing unit (CPU) 1601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1602 or a program loaded from a storage part 1608 into a random access memory (RAM) 1603. In the RAM 1603, various programs and data required for the operation of the system 1600 are also stored. The CPU 1601, the ROM 1602, and the RAM 1603 are connected to each other via a bus 1604. An input / output (I / O) interface 1605 is also connected to the bus 1604.
[0177] The following components are connected to the I / O interface 1605: an input section 1606 including a keyboard, a mouse, etc.; an output section 1607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 1608 including a hard disk, etc.; and a communication section 1609 including a network interface card such as a LAN card, a modem, etc. The communication section 1609 performs communication processing via a network such as the Internet. A drive 1610 is also connected to the I / O interface 1605 as needed. A removable medium 1611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 1610 as needed, so that a computer program read therefrom is installed into the storage section 1608 as needed.
[0178] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 1609, and / or installed from the removable medium 1611. When the computer program is executed by the central processing unit (CPU) 1601, the above-mentioned functions defined in the system of the present invention are executed.
[0179] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0180] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0181] The modules involved in the embodiments of the present invention may be implemented by software or hardware. The modules described may also be set in a processor, for example, it may be described as: a processor includes a first type confirmation module, a second type confirmation module, a test data determination module, and a test module. The names of these modules do not constitute a limitation on the modules themselves in some cases, for example, the test module may also be described as "a module for testing the first business system using test data".
[0182] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes: determining a first business type corresponding to a first business system to be tested; determining a second business type corresponding to the first business type according to a business mapping relationship; determining business data of the second business type running in the second business system, and using the business data as test data; and testing the first business system using the test data.
[0183] According to the technical solution of the embodiment of the present invention, after determining the first business type corresponding to the first business system to be tested, the business data of the second business type corresponding to the first business type run by the second business system can be used as test data to test the first business system according to the business mapping relationship, thereby eliminating the need for technical personnel to manually write test data, and using the business data obtained from the operation of the existing second business system as test data can also cover more real usage scenarios, thereby being able to more completely test the first business system and improve the accuracy and efficiency of the test.
[0184] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A business system testing method, characterized in that: include: Determine a first service type corresponding to a first service system to be tested; Determine, according to the service mapping relationship, a second service type corresponding to the first service type; Determine business data of the second business type running in the second business system, and use the business data as test data; wherein the business data includes a data tag and a business value, and using the business data as test data includes: for each of the first business types, perform: determine a first data tag corresponding to the first business type, and extracted target business data corresponding to the first business type; determine a second data tag corresponding to the first data tag and a second business value corresponding to the second data tag from the target business data according to the first data tag; use the second business value as test data corresponding to the first data tag; The first business system is tested using the test data.
2. The method according to claim 1, characterized in that The determining of the service data of the second service type running in the second service system includes: Determining message data of the second business system; The service data corresponding to the second service type is extracted from the message data.
3. The method according to claim 1, characterized in that According to a preset error range table, a first data tag to be tested is determined; wherein the allowable error range of the first data tag to be tested is greater than a preset threshold; the error range table includes: one or more data tags, and an allowable error range corresponding to each of the data tags; A second data tag corresponding to the first data tag to be tested and a second service value corresponding to the second data tag are determined from the target service data.
4. The method according to claim 1, characterized in that: The determining, from the target service data, a second data tag corresponding to the first data tag comprises: Determining a plurality of second data tags included in the target business data; The plurality of second data tags are traversed to find a second data tag corresponding to the first data tag.
5. The method according to claim 4, characterized in that When the character string corresponding to the second data tag is included in the character string corresponding to the first data tag, it is determined that the second data tag corresponds to the first data tag.
6. The method according to claim 4, characterized in that According to a preset tag correspondence table, the second data tag corresponding to the first data tag is determined from the target business data.
7. The method according to claim 1, characterized in that The business data is used as test data, including: Determining a first data type required by the first business system; Determining a second data type of the business data; Determine whether the first data type and the second data type are the same; if not, convert the business data according to the first data type, and use the converted business data as the test data.
8. The method according to claim 7, characterized in that The converting the service data according to the first data type includes: Constructing a decoding mapping table; wherein the decoding mapping table includes: multiple data types, multiple characters included in each of the multiple data types, and character correspondences between different data types; The service data is converted according to the decoding mapping table.
9. The method according to claim 8, characterized in that The converting the service data according to the decoding mapping table includes: Determine a second data type corresponding to the service data from the decoding mapping table, and determine a plurality of characters to be converted included in the service data from a plurality of characters corresponding to the second data type; Determine in the decoding mapping table a plurality of characters corresponding to the first data type; According to the character correspondence between the first data type and the second data type in the decoding mapping table, the target character corresponding to each of the characters to be converted is determined among the multiple characters corresponding to the first data type, so as to convert the business data.
10. The method according to any one of claims 1 to 9, characterized in that: The first business system and the second business system are financial transaction systems; The first business type includes any one or more of the following: contract-level account tracking, channel outreach account tracking, cash flow account tracking and detailed account tracking.
11. The method according to claim 1, characterized in that: When the first business type is contract-level account tracking, The test data is used to test foreign exchange transactions and borrowing transactions.
12. The method according to claim 11, characterized in that The first data tag corresponding to the foreign exchange transaction includes any one or more of the following: the product type, transaction date, expiration and delivery, counterparty abbreviation, transaction currency pair, transaction direction, currency, amount corresponding to the currency, payment date, pricing exchange rate and non-deliverable forward foreign exchange transaction interest rate date corresponding to the foreign exchange transaction; and / or, The first data tag corresponding to the repo transaction includes any one or more of the following: the product type corresponding to the repo transaction, transaction date, interest accrual date, maturity date, counterparty abbreviation, currency code, transaction amount, maturity repayment amount, interest, interest rate type, fixed interest rate value, fixed interest calculation rules, floating interest rate benchmark, interest spread, floating interest calculation rules, interest calculation method, reset frequency, reset holidays, reset period, payment holidays, payment holiday rules, interest calculation frequency, interest calculation adjustment method, interest calculation calendar, and interest settlement method.
13. The method according to claim 1, characterized in that When the first business type is channel external liaison and account tracking, The first data tag includes any one or more of the following: clearing currency code, actual clearing amount, sending bank number, receiving bank number, payee account name, payee account number, payee account opening bank number, payee account opening bank name, beneficiary bank number, payee account name, beneficiary address, beneficiary account number, beneficiary account opening bank number, and beneficiary account opening bank name.
14. The method according to claim 1, characterized in that When the first business type is cash flow tracking, The first data tag includes any one or more of the following: the business type corresponding to the cash flow, the short name of the counterparty, the clearing currency code, the custom name of the remittance path, and the clearing path category code.
15. The method according to claim 1, characterized in that When the first business type is detailed account tracking, The first data tag includes any one or more of the following: accounting date, product contract number, transaction institution number, account institution number, multi-entity identifier, currency code, account direction code, natural account number, off-balance sheet account mark, detailed entry transaction amount, account responsibility center number, public customer type code, correspondent institution number, and general ledger term code.
16. A testing device for a business system, characterized in that: It includes a first type confirmation module, a second type confirmation module, a test data determination module and a test module; wherein: The first type confirmation module is used to determine a first service type corresponding to a first service system to be tested; The second type confirmation module is used to determine a second service type corresponding to the first service type according to the service mapping relationship; The test data determination module is used to determine the business data of the second business type running in the second business system, and use the business data as test data; wherein the business data includes a data tag and a business value, and using the business data as test data includes: for each of the first business types, performing: determining a first data tag corresponding to the first business type, and the extracted target business data corresponding to the first business type; determining a second data tag corresponding to the first data tag and a second business value corresponding to the second data tag from the target business data according to the first data tag; and using the second business value as the test data corresponding to the first data tag; The testing module is used to test the first business system using the testing data.
17. An electronic device for testing a business system, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 15.
18. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 15 is implemented.