CN118075169A - Method and device for testing network switching equipment, storage medium and electronic device - Google Patents

Method and device for testing network switching equipment, storage medium and electronic device Download PDF

Info

Publication number
CN118075169A
CN118075169A CN202410434783.8A CN202410434783A CN118075169A CN 118075169 A CN118075169 A CN 118075169A CN 202410434783 A CN202410434783 A CN 202410434783A CN 118075169 A CN118075169 A CN 118075169A
Authority
CN
China
Prior art keywords
test
network switching
target
switching equipment
keyword
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202410434783.8A
Other languages
Chinese (zh)
Inventor
刘琪
张敏莹
王乐康
潘园园
郑辙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sunwave Communications Co Ltd
Original Assignee
Sunwave Communications Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sunwave Communications Co Ltd filed Critical Sunwave Communications Co Ltd
Priority to CN202410434783.8A priority Critical patent/CN118075169A/en
Publication of CN118075169A publication Critical patent/CN118075169A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0817Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking functioning
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/14Arrangements for monitoring or testing data switching networks using software, i.e. software packages
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Environmental & Geological Engineering (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a method and a device for testing network switching equipment, a storage medium and an electronic device, wherein the method comprises the following steps: receiving a target test request for the network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements; responding to the target test request, and analyzing service items required to be tested by the target test requirement; configuring a target test program for a service item, and constructing a target test case of the network switching equipment according to the item attribute of the service item; and calling a target test program according to the target test case to test the network switching equipment to obtain a target test result. By adopting the technical scheme, the problem of lower testing efficiency of the network switching equipment is solved, and the technical effect of improving the testing efficiency of the network switching equipment is achieved.

Description

Method and device for testing network switching equipment, storage medium and electronic device
Technical Field
The present application relates to the field of communications, and in particular, to a method and apparatus for testing a network switching device, a storage medium, and an electronic apparatus.
Background
The network switching device is a key component for constructing modern network communication and is responsible for forwarding data packets between network devices, so that data can be efficiently and accurately transmitted from one data node to another data node, and the performance requirements on the network switching device are higher and higher along with the continuous development of network technology and continuous expansion of network scale. In order to determine that the network switching device has excellent performance after being put into use, performance testing becomes an important link of the network switching device. Currently, the test of the network switching equipment is mainly finished by manually operating a tester, namely, the tester executes corresponding actions on the network switching equipment according to the test requirement of the network switching equipment, so that the operation of the network equipment is controlled.
Aiming at the problems of low test efficiency and the like of network switching equipment in the related technology, no effective solution is proposed yet.
Disclosure of Invention
The embodiment of the application provides a method and a device for testing network switching equipment, a storage medium and an electronic device, which are used for at least solving the problems of low testing efficiency and the like of the network switching equipment in the related technology.
According to an embodiment of the present application, there is provided a method for testing a network switching device, including: receiving a target test request for network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
responding to the target test request, and analyzing service items required to be tested by the target test requirement;
configuring a target test program for the service item, and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein test logic for testing the service item is recorded in the target test program, and a test time sequence for testing the service item of the network switching equipment by using the target test program is recorded in the target test case;
and calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
Optionally, the calling the target test program according to the target test case tests the network switching device, including:
Acquiring keyword sequences of a plurality of item keywords of a plurality of business items to be tested, wherein each item keyword is used for indicating a storage position of the target test program of the corresponding business item, and the keyword sequences are recorded in the target test case;
and calling the item keywords according to the keyword sequence to test the network switching equipment.
Optionally, the step of calling the item keyword according to the keyword sequence to test the network switching device includes:
calling a first test program by using a first keyword, wherein the first test program is used for enabling the running state of the network switching equipment to be changed;
under the condition that the running state of the network switching equipment is regulated to be the running state for executing equipment performance test, a second keyword is used for calling a second test program to test file updating performance of the network switching equipment, wherein the second test program is used for sending a network configuration file to be updated to the network switching equipment, detecting an updating result of the network switching equipment on the network configuration file, and recording data used by the network switching equipment when carrying out data transmission service in the network configuration file;
under the condition that the second test program is determined to be operated, a third key word is used for calling a third test program to test the restarting performance of the network switching equipment, wherein the third test program is used for controlling the network switching equipment to execute equipment restarting operation;
Under the condition that the third test program is determined to be operated, a fourth keyword is used for calling a fourth test program to test the data transmission capacity of the network switching equipment under different signal strengths, wherein the fourth test program is used for adjusting the attenuation value of a signal attenuator to a signal transmitted to the network switching equipment;
Under the condition that the fourth test program is determined to be operated, a fifth test program is called by using a fifth keyword to perform user equipment access test on the network switching equipment, wherein the fifth test program is used for controlling the network switching equipment to execute user equipment access operation;
And under the condition that the network switching equipment is accessed with target user equipment, a sixth keyword is used for calling a sixth test program to perform data transmission test on the network switching equipment, wherein the sixth test program is used for controlling the network switching equipment to perform data exchange with the target user equipment, the project keywords comprise the first keyword, the second keyword, the third keyword, the fourth keyword, the fifth keyword and the sixth keyword, and the target test program comprises the first test program, the second test program, the third test program, the fourth test program, the fifth test program and the sixth test program.
Optionally, the invoking a sixth test program by using a sixth keyword performs a data transmission test on the network switching device, including:
A first sub-test program is called by using a first sub-keyword to execute a parameter acquisition test on the network switching equipment, wherein the first sub-test program is used for controlling the network switching equipment to acquire data transmission parameters from the target user equipment, and the data transmission parameters are used for indicating a transmission mode of parameter transmission between the network switching equipment and the target user equipment;
under the condition that the running of the first sub-test program is determined to be finished, a second sub-test program is called by using a second sub-keyword to perform a packet filling test on the network switching equipment, wherein the second sub-test program is used for controlling the transmission of data packets between the network switching equipment and the target user equipment by using the data transmission parameters;
And calling a third sub-test program to collect test results of the pack test by using a third sub-keyword, wherein the third sub-test program is used for collecting data transmission parameters between the network switching equipment and the target user equipment, the sixth keyword comprises the first sub-keyword, the second sub-keyword and the third sub-keyword, and the sixth test program comprises the first sub-test program, the second sub-test program and the third sub-test program.
Optionally, the configuring the target test program for the service item includes:
Calling an initial test script corresponding to the service item, wherein universal test logic used when testing corresponding test conditions are carried out on the service item is recorded in the initial test script;
And inputting the test variable indicated by the test requirement into the initial test script to obtain a target test script, wherein the target test program comprises the target test script.
Optionally, the constructing the target test case of the network switching device according to the item attribute of the service item includes:
in case the number of the service items is plural, determining a test order of the plurality of the service items according to the item attribute,
And ordering the item keywords of each of the plurality of business items according to the test sequence to obtain a keyword sequence, wherein the keyword sequence is recorded in the target test case, and each item keyword is used for indicating the storage position of the target test program of the corresponding business item.
Optionally, after the target test program is called according to the target test case to test the network switching device to obtain a target test result, the method further includes:
generating a target notification message carrying the target test result;
and sending the target notification message to a target account corresponding to the network switching equipment, wherein the target account is used for performing performance maintenance on the network switching equipment according to the target test result.
According to another embodiment of the present application, there is further provided a testing apparatus for a network switching device, including: the receiving module is used for receiving a target test request for the network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
the response module is used for responding to the target test request and analyzing service items required to be tested by the target test requirement;
the processing module is used for configuring a target test program for the service item and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein the target test program records test logic for testing the service item, and the target test case records test time sequence for testing the service item of the network switching equipment by using the target test program;
and the test module is used for calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
According to a further aspect of embodiments of the present application, there is also provided a computer readable storage medium having a computer program stored therein, wherein the computer program is arranged to perform the above method when run.
According to still another aspect of the embodiment of the present application, there is further provided an electronic apparatus including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor executes the method for testing the network switching device through the computer program.
According to a further embodiment of the application, there is also provided a computer program product comprising a computer program which, when executed by a processor, implements the steps of any of the method embodiments described above.
In the embodiment of the application, a target test request for network switching equipment is received, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements; responding to the target test request, and analyzing service items required to be tested by the target test requirement; configuring a target test program for the service item, and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein test logic for testing the service item is recorded in the target test program, and a test time sequence for testing the service item of the network switching equipment is recorded in the target test case; and calling the target test program according to the target test case to test the network switching equipment to obtain a target test result. The method comprises the steps of analyzing target test requirements indicated by a received target test request, determining a service item of the network switching equipment requested by the target test request, configuring a corresponding target test program for the service item, constructing a target test case indicating a test time sequence for testing the service item of the network switching equipment by using the target test program according to the item attribute of the service item, calling the target test program by using the target test case when testing, and testing the network switching equipment according to the target test requirements, thereby avoiding complex operation of manual test by a tester and test faults caused by unskilled test service in the related art. By adopting the technical scheme, the problem of lower testing efficiency of the network switching equipment in the related technology is solved, and the technical effect of improving the testing efficiency of the network switching equipment is achieved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the application or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, and it will be obvious to a person skilled in the art that other drawings can be obtained from these drawings without inventive effort.
Fig. 1 is a schematic diagram of a hardware environment of a method for adjusting an operation parameter of a repeater according to an embodiment of the present application;
FIG. 2 is a flow chart of an alternative method of testing a network switching device according to an embodiment of the present application;
FIG. 3 is a schematic diagram of an alternative network switching device testing system according to an embodiment of the present application;
FIG. 4 is a schematic diagram of an alternative network switching device test according to an embodiment of the present application;
FIG. 5 is a flow chart of an alternative network switching device test according to an embodiment of the present application;
fig. 6 is a block diagram of a test apparatus of a network switching device according to an embodiment of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The method embodiments provided by the embodiments of the present application may be performed in a computer terminal, a device terminal, or a similar computing apparatus. Taking a computer terminal as an example, fig. 1 is a schematic diagram of a hardware environment of a method according to an embodiment of the present application. As shown in fig. 1, the computer terminal may include one or more (only one is shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a microprocessor MCU or a processing device such as a programmable logic device FPGA) and a memory 104 for storing data, and in one exemplary embodiment, may also include a transmission device 106 for communication functions and an input-output device 108. It will be appreciated by those skilled in the art that the configuration shown in fig. 1 is merely illustrative and is not intended to limit the configuration of the computer terminal described above. For example, a computer terminal may also include more or fewer components than shown in FIG. 1, or have a different configuration than the equivalent functions shown in FIG. 1 or more than the functions shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program of application software and a module, such as a computer program corresponding to a method for sending message push in an embodiment of the present invention, and the processor 102 executes the computer program stored in the memory 104, thereby performing various functional applications and data processing, that is, implementing the method described above. Memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory remotely located relative to the processor 102, which may be connected to the computer terminal via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used to receive or transmit data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of a computer terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, simply referred to as a NIC) that can connect to other network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is configured to communicate with the internet wirelessly.
In this embodiment, a method for testing a network switching device is provided, and fig. 2 is a flowchart of an alternative method for testing a network switching device according to an embodiment of the present application, as shown in fig. 2, including at least the following steps:
Step S202, receiving a target test request for network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
step S204, responding to the target test request, analyzing the service items required to be tested by the target test requirement;
Step S206, a target test program is configured for the service item, and a target test case of the network switching equipment is constructed according to the item attribute of the service item, wherein the target test program records test logic for testing the service item, and the target test case records test time sequence for testing the service item of the network switching equipment by using the target test program;
And step S208, calling the target test program according to the target test case to test the network switching equipment, so as to obtain a target test result.
Through the steps, the service item of the network switching equipment requested by the target test request is determined by analyzing the target test requirement indicated by the received target test request, the corresponding target test program is configured for the service item, and the target test case for indicating the test time sequence for testing the service item of the network switching equipment by using the target test program is constructed according to the item attribute of the service item, so that the target test case can be used for calling the target test program when the test is performed, the network switching equipment is tested according to the target test requirement, and the complex operation of manual test by a tester and the test faults caused by unskilled test service in the related art are avoided. By adopting the technical scheme, the problem of lower testing efficiency of the network switching equipment in the related technology is solved, and the technical effect of improving the testing efficiency of the network switching equipment is achieved.
The test method of the network switching equipment provided by the embodiment of the application can be deployed on a test platform for testing the equipment performance of the network switching equipment, and the test platform can be, but is not limited to, an X86 and 5G NXP test platform of SW. Fig. 3 is a schematic diagram of an alternative network switching device testing system according to an embodiment of the present application, as shown in fig. 3: and (3) setting up an environment of an automatic platform system, and controlling a service server, a BBU server, an electronic attenuator and a terminal through an automatic code on a PC.
In the embodiment provided in step S202, the network switching device is a device for transmitting data between network nodes, and the network switching device may include, but is not limited to, a switch, a router, a base station, a bridge, and the like, which is not limited in this aspect.
Optionally, in the embodiment of the present application, the target test requirement is used to indicate test information for testing the service item of the network device, where the test information includes, but is not limited to, a service item condition of the network device to be tested, and a test condition of the service item (such as a test time of the service item, a test scenario of the service item, a test period of the service item, etc.), which is not limited.
In the embodiment provided in step S204, the number of service items required to be tested by the target test requirement may include one or more of, that is, testing the device performance of a single dimension of the network device or testing the device performance of dimensions of multiple network devices, which is not limited in this scheme.
Optionally, in the embodiment of the present application, the service item required to be tested by the target test requirement may be obtained by performing semantic recognition on the target test request, or may also be obtained by performing keyword recognition on the target test request, so as to obtain a keyword corresponding to the service test requirement, and further determine the test requirement corresponding to the keyword as the target test requirement.
In the embodiment provided in step S206, the operation function for implementing the related operation of testing the service item is recorded in the target test program, which may be a single operation of a single operation function or may be an operation set formed by a plurality of operation functions, which is not limited in this scheme.
Optionally, in the embodiment of the present application, the target test program may be a test program that is screened from a plurality of test programs configured for the network switching device and matches with a service item to be tested, or the target test program may also be obtained by modifying an initial test script according to a test requirement for the service item, where a test in which a test corresponding to the test requirement for the service item is recorded in the initial test script is a used general test logic.
Alternatively, in the embodiment of the present application, the item attribute may be, but is not limited to, an item handling condition for indicating a business item or an item type of the business item, which is not limited in this aspect.
In the embodiment provided in step S208, the target test case may store the target test program according to the execution sequence of the test program, or may also be call information corresponding to the target test program stored according to the execution sequence of the test program, where the call information is used to call the corresponding target test program.
Optionally, the method for testing the network switching device provided by the embodiment of the application can realize the automatic performance test of the network switching device by developing the python script under the framework based on robotframework. FIG. 4 is a schematic diagram of an alternative network switching device test, as shown in FIG. 4, according to an embodiment of the present application, test case code development is implemented primarily by running code within SW_ autotest and SWlibrary files.
The running code in the SW_ autotest file is realized, and SW_ autotest is mainly divided into variables, a robot keyword, a test case and a batch running result;
The variables: placing all variables into a configuration file, wherein the configuration file comprises address configuration, package filling configuration, package grabbing configuration, other configurations and the like;
robot key: all python methods or rf keywords can be combined into one total keyword;
test cases: the method comprises the steps of referring to variables and robot keywords in a main window of a running program, wherein the variables and the robot keywords comprise service flow, signaling analysis, parameter modification, alarm verification and repeated operation class use cases;
batch running results: the batch result log (recorded is the log and data of the execution case) and the batch result report (recorded is the key word flow of robotframework and the key word flow of python, and also the whole test result);
the SWlibrary file mainly comprises a developed python bottom layer method, and 90 python keyword methods in total, and the python bottom layer method comprises a terminal class, a linux operation class, an xml configuration class, a packet grabbing class, a window operation class, a wed operation class, an electronic attenuation class, an integration method class, a UI click class and the like.
Fig. 5 is a flowchart of another alternative testing of a network switching device according to an embodiment of the present application, as shown in fig. 5, at least including the following steps:
Step S501, a python bottom layer method is developed, basic function development is achieved, the basic function development is embedded into robotframework frames, and the basic function development is mutually nested to form a complete use case, wherein 90 python keyword methods in total comprise a terminal class, a linux operation class, an xml configuration class, a packet grabbing class, a window operation class, a wed operation class, an electronic attenuation class, an integration method class, a UI click class and the like. Table 1 is an alternative python method table according to an embodiment of the present application, as shown in table 1,
TABLE 1
And step S502, constructing robotframework a test platform. The python, pycharm and robotframwork plug-ins are installed for environment variable configuration and debugging. Importing a configuration file and a python library. Executing batch runs, robotframwork framework generates output results (pass or fail), reports, and logs.
Step S503,3, developing an automatic test case. After the bottom python method is debugged and passed, the debug robot key is quoted by the robot key, whether the debug robot key is correct and accords with logic, and the use case consists of a plurality of keys.
In step S504, the network switching device is tested by using the test case to call the bottom layer python, so that the test result is presented in the form of a notification message. The presentation of the specific test results can be realized by the following modes:
1) windows10 system installation jenkins and configuration, installation plug-in Email Extension Template Plugin, robot Framework;
2) Downloading and installing JDK11, JRE generation and environment configuration;
3) Configuring a Jenkins master node and a Jenkins slave node, and constructing a build task;
4) Constructing a finished sending mail by Jenkins+ RobotFramework, and modifying the css code of a mail template;
5) Automatically constructing projects, outputting construction results and sending result mails.
As an optional embodiment, the calling the target test program according to the target test case to test the network switching device includes:
Acquiring keyword sequences of a plurality of item keywords of a plurality of business items to be tested, wherein each item keyword is used for indicating a storage position of the target test program of the corresponding business item, and the keyword sequences are recorded in the target test case;
and calling the item keywords according to the keyword sequence to test the network switching equipment.
Optionally, in the embodiment of the present application, the keyword sequence is used to indicate a sequence of the target test programs of the plurality of services to be tested, and/or the attribution relationship, that is, the plurality of target test programs may have an attribution relationship of an upper level and a lower level, besides the sequence relationship, the upper level keyword is used to call the lower level keyword, that is, when a certain test is executed, a plurality of target test programs need to be executed in parallel, at this time, the keywords of the plurality of target test programs may be set as the lower level keyword, and an upper level keyword is set for the plurality of lower level keywords, when the lower level keyword is used, the plurality of lower level keywords are called through the upper level keyword, and when the corresponding target test program is called through the lower level keyword, the scheme is not limited.
Optionally, in the embodiment of the present application, the target test program is stored in a storage space corresponding to the network switching device, and the target test program in the storage space is called by a keyword, so that when tests with different test requirements are executed, the target test program can be multiplexed by the keyword, which is not limited in this scheme.
Through the above, by configuring the keywords for each test program and recording the keyword sequence of the target keywords in the target test case, the target test program can be called through the keywords, the occupation condition of the target test program on the memory is avoided from being directly stored in the test case, and the execution efficiency of the program is improved.
As an optional embodiment, the calling the item keyword according to the keyword sequence tests the network switching device, including:
calling a first test program by using a first keyword, wherein the first test program is used for enabling the running state of the network switching equipment to be changed;
under the condition that the running state of the network switching equipment is regulated to be the running state for executing equipment performance test, a second keyword is used for calling a second test program to test file updating performance of the network switching equipment, wherein the second test program is used for sending a network configuration file to be updated to the network switching equipment, detecting an updating result of the network switching equipment on the network configuration file, and recording data used by the network switching equipment when carrying out data transmission service in the network configuration file;
under the condition that the second test program is determined to be operated, a third key word is used for calling a third test program to test the restarting performance of the network switching equipment, wherein the third test program is used for controlling the network switching equipment to execute equipment restarting operation;
Under the condition that the third test program is determined to be operated, a fourth keyword is used for calling a fourth test program to test the data transmission capacity of the network switching equipment under different signal strengths, wherein the fourth test program is used for adjusting the attenuation value of a signal attenuator to a signal transmitted to the network switching equipment;
Under the condition that the fourth test program is determined to be operated, a fifth test program is called by using a fifth keyword to perform user equipment access test on the network switching equipment, wherein the fifth test program is used for controlling the network switching equipment to execute user equipment access operation;
And under the condition that the network switching equipment is accessed with target user equipment, a sixth keyword is used for calling a sixth test program to perform data transmission test on the network switching equipment, wherein the sixth test program is used for controlling the network switching equipment to perform data exchange with the target user equipment, the project keywords comprise the first keyword, the second keyword, the third keyword, the fourth keyword, the fifth keyword and the sixth keyword, and the target test program comprises the first test program, the second test program, the third test program, the fourth test program, the fifth test program and the sixth test program.
Alternatively, in the embodiment of the present application, the first keyword may be, but not limited to, gnb _is_kill keyword, and by using the gnb _is_kill keyword, the first test program is invoked to perform the station killing operation on the network switching device. The specific calling mode is as follows:
KEYWORD building. Comment [ base station kill operation and determine if base station kill was successful ] [00:00:00.000]
Documentation:Displays the given messages in the log file as keyword argument.
Start/End/Elapsed:20231027 17:54:42.774/20231027 17:54:42.774/00:00:00.000
KEYWORD${result}=SWLibrary.Gnb ls Kill${linux_url},${linux_username},${linux_password}
Documentation the functions are as follows: base station killing operation and judging whether base station killing is successful: param linux_url Linux server Address: param linux_username Linux system login user name: param linux_password: linux system login password: param linux_command command, command executed in Linux System: return to wire or false
Start/End/Elapsed:20231027 17:54:42.774/20231027 17:54:54.371/00:00:11.597 17:54:54.371INFO['Killing All processes']
17:54:54.371 INFO $ { result } = True optionally, in the embodiment of the present application, the second key may be, but not limited to, an xml_is_success key, and the XML is_success key is called to call the second test program to execute an XML modification operation on the network switching device and upload an XML file, where the XML file records parameter information used by the network switching device for data transmission. The specific calling mode is as follows:
KEYWORD${result1}=SWLibrary.Xml ls success${linux_url},${linux_username},${linux_password},${filename1},${filename2},${input_path_filename},${xml_config},${xml_config_level},${testfilename},${casename},${linux_file_path}00:00:01.009
Documentation deleting the xml file of the linux server, modifying the xml, and uploading the xml to the linux server: param linux_url Linux server Address: param linux_username Linux system login user name: param linux_password: linux system login password: param linux_command command, command executed in Linux System: PARAM FILENAME1 delete xml PARAM FILENAME delete xml backup: paraminput _path_filename: path xml file before modification: param xml_config: modify parameter values (dictionary form): param xml_config_level: level of modification parameters: optional-cell_level/gnb _level: PARAM TESTFILENAME: folder name: PARAM CASENAME use case name param linux_file_name: linux server file path, case: r '/version/oam _xml/omc _domain_bak2.Xml': retum: return print information
Start/End/Elapsed:20231027 17:54:54.371/20231027 17:54:55.380/00:00:01.009
17:54:55.380 INFO delete files rm-rf/opt/bbu/oam/cm/confdb _v2.Xml successful delete files rm-rf/opt/bbu/oam/cm/confdb _v2.Xml. Back values before successful modification are: DSUUUDSUUU A
The modified values are: DDDSUDDDSU A
The pre-modification values are: 10:2
The modified values are: 10:2
The pre-modification values are: 0
The modified values are: 0
The pre-modification values are: 5
The modified values are: 5
The pre-modification values are: 1
The modified values are: 3
The pre-modification values are: 10
The modified values are: 10
The pre-modification values are: 3
The modified values are: 1
The pre-modification values are: 2
The modified values are: 2
The pre-modification values are: 5
The modified values are: 5
The pre-modification values are: 1
The modified values are: 1
The pre-modification values are: 10
The modified values are: 10
The pre-modification values are: 3
The modified values are: 3
The pre-modification values are: 2
The modified values are: 2
The pre-modification values are: 640608
The modified values are: 642624
The pre-modification values are: 643334
The modified values are: 643334
The pre-modification values are: 643334
The modified values are: 643334
The pre-modification values are: 100
The modified values are: 40
The pre-modification values are: 100
The modified values are: 40
The pre-modification values are: 273
The modified values are: 106
The pre-modification values are: 53
Optionally, in an embodiment of the present application, the third key may be, but not limited to, gnb _is_success key, and the third test program is called by calling gnb _is_success key to perform a device restart operation on the network switching device. The specific calling mode is as follows:
KEYWORD${result2}=SWLibrary.Gnb ls success${linux_ur},${linux_username},${linux_password},${testfilename},${casename}00:03:23.102
Documentation the function of starting operation of the base station and judging whether the base station is successful: param linux_url Linux server Address: param linux_username Linux system login user name: param linux_password: linux system login password: PARAM CASENAME use case name: return to wire or false
Start/End/Elapsed:20231027 17:54:55.395/20231027 17:58:18.497/00:03:23.102
17:58:18.497 INFO spawn-ignore SIGINT-ignore SIGHUP ssh–t–o StrictHostKeyChecking=no–i~/.ssh/bbu_rsa root@127.0.0.1Last login:Fri 0ct 27 09:42:03 2023from 127.0.0.1[root@localdomain~]#nohup sp.sh–oam>/opt/bbu/oam/log/restart.log&[1]100871[root@localdomain~]#nohup:ignoring input and redirecting stderr to stdout Killed by signal 15.
exit
SW_ autotest \result\log\ testcase _20231027_174237\4OM_3D1U_256qam_4T4R downstream TCP traffic authentication\output\bbu.start_2023-10-27-17-58-17.tx192.168.5.111-file :/opt/bbu/oam/log/bbu.startup===>D:\SW_autotest\result\log\testcase_20231027_174237\4OM_3D1U_256qam_4T4R downstream TCP traffic authentication\output\bbu.start_2023-10-27-17-58-17.txt, successful download 2023/10/27 CST 09:48:58.298236 MAC-PHY synchronization DONE-!
MAC-PHY synchronization success-! ! !
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
['1','3','3','3','3','3','3','3','3','3','3','3','3','3']
14
P value of 14
Normal start of base station
17:58:18.497INFO$[result2]=True
Optionally, in an embodiment of the present application, the fourth keyword may be, but not limited to, att_ allwrite keyword, and call the att_ allwrite keyword to call the fourth test program to adjust the attenuation value of the signal attenuator corresponding to the network switching device to be the target value. The specific calling mode is as follows:
KEYWORD${value}=SWLibrary.Att Allwrite 00.00
documentation function of all electronic attenuation write attenuation values: param value attenuation value format xx. Xx: return
Start/End/Elapsed:20231027 17:58:18.497/20231027 17:58:19.367/00:00:00.870
17:58:19.367 INFO[<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B748>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B448>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319BE88>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B588>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B648>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B208>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D319B108>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D3209CC8>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D3209948>,<serial.tools.list_ports_common.ListPortInfo object at 0x00000253D3209988>]
The serial devices available are as follows:
Port detection success-! ! !
[’COM11’,’COM12’,’COM13’,’COM14’]
[’COM11’,’COM12’,’COM13’,’COM14’]
The serial port is successfully opened.
COM11
Successful write 00.00
The serial port is successfully opened.
COM12
Successful write 00.00
The serial port is successfully opened.
COM13
Successful write 00.00
The serial port is successfully opened.
COM14
Successful write 00.00
[True,True,True,True]
17:58:19.367 INFO$[value]=00.00
Optionally, in the embodiment of the present application, the fifth keyword may, but is not limited to, include a ue_is_success keyword, and the ue_is_success keyword is called to perform a terminal access operation on the network switching device and perform packet capturing. The specific calling mode is as follows:
KEYWORD${result3},${tag}=SWLibrary.Phone ls Success${web_url},${start_dump},${stop_dump},${time},${testfilename},${casename},${msg},${interface},${use_ip}00:00:34.966
Documentation, the function of accessing the mobile phone and judging whether the access is successful or not, wherein the function is that: PARAM START _dump command to start packet capture (optional: signalling plane/fapi 1/fapi 3) param stop_dump command to end packet capture (optional: signalling plane/fapi 1/fapi 3): PARAM TIMES time interval of packet grabbing: PARAM TESTFILENAME folder name: PARAM CASENAME use case name: parammsg: PARAMINTERFACE packet-grabbing interface type: paramuse_ip, execute network management operation ip: return to wire or false
Start/End Elapsed:20231027 17:58:19.367/20231027 17:58:54 333/00:00:34.966
17:58:54.333 INFO obtains the connection state: 101
The result :Json=MSG_LENGTH:00000295,00000003{'MSG_TYPE':'MML','CMD_SOURCE':'WebLMT','USER_NAME':'admin','status':'0','MML_CONTENT':'+++BTI 2023-10-27 09:50:45<br/>O&M #1<br/>%%STR CaughtTask:SelectType=TransmitCaught,SelectMsg=1,cellIndex=1,TransmitIP=192.168.5.37;%%<br/>RETCODE=0 is received and the command is successfully executed. < br/> -END < br/>' }
The start of the grabbing of the bag
The device 9Y90219002012954 is connected
Successful terminal flight operation
Successful terminal flight removal operation
Acquiring a connection state: 101
The result :Json=MSG_LENGTH:00000222,00000004{'MSG_TYPE':'MML','CMD_SOURCE':'WebLMT','USER_NAME':'admin','status':'0','MML_CONTENT':'+++BTI 2023-10-27 09:51:14<br/>O&M#2<br/>%%STP CaughtTask:%%<br/>RETCODE=0 is received and the command is successfully executed. < br/> -END < br/>' }
End of grabbing bag
Alternatively, in an embodiment of the present application, the sixth key may include, but is not limited to, an analysis_pcap key, and the analysis_pcap package is analyzed by calling the analysis_pcap key. The specific calling mode is as follows:
Performing bale breaking analysis
The Pcap data packet exists: PDUSessionResourceSetupResponse A
17:58:54.333 INFO${result3}=True
As an optional embodiment, the invoking the sixth test program with the sixth key to perform the data transmission test on the network switching device includes:
A first sub-test program is called by using a first sub-keyword to execute a parameter acquisition test on the network switching equipment, wherein the first sub-test program is used for controlling the network switching equipment to acquire data transmission parameters from the target user equipment, and the data transmission parameters are used for indicating a transmission mode of parameter transmission between the network switching equipment and the target user equipment;
under the condition that the running of the first sub-test program is determined to be finished, a second sub-test program is called by using a second sub-keyword to perform a packet filling test on the network switching equipment, wherein the second sub-test program is used for controlling the transmission of data packets between the network switching equipment and the target user equipment by using the data transmission parameters;
And calling a third sub-test program to collect test results of the pack test by using a third sub-keyword, wherein the third sub-test program is used for collecting data transmission parameters between the network switching equipment and the target user equipment, the sixth keyword comprises the first sub-keyword, the second sub-keyword and the third sub-keyword, and the sixth test program comprises the first sub-test program, the second sub-test program and the third sub-test program.
Alternatively, in the embodiment of the present application, the first sub-key may be, but not limited to, get_cpe_ ATTACHMESSAGE key, and the address value crnti, rsrp, ip on the ue side is obtained by calling the get_cpe_ ATTACHMESSAGE key. The specific calling mode is as follows:
KEYWORD${val1).${val2)=SWLibrary.Analysis Pcap${testfilename}${casename},C-RNTI
Documentation the functions are as follows: judging whether expected information exists in the data packet: PARAM TESTFILENAME: folder name: PARAM CASENAME: case name: param msg: the expected information present in the data packet: return: the expected information exists, returns True, does not exist, returns Flase
Start/End/Elapsed:20231027 17:58:54.333/20231027 17:58:57.783/00:00:03.450
17:58:57.783 INFO carry out a bale plucking analysis
The pcap data packet exists: C-RNTI
93
The pcap data packet exists: C-RNTI
125
The pcap data packet exists: C-RNTI
125
KEYWORD SWLibrary.Get Device Rsrp${testfilename},${casename}
Documentation the functions are as follows: rsrp after the mobile phone is accessed is obtained: return: rsrp of the return device
Start/End/Elapsed:20231027 17:58:57.799/20231027 17:59:11.950/00:00:14:151
17:59:11.950 INFO device 9YS0219C02012954 is connected to
17:59:11.950 INFO$[result9]=-74
KEYWORD SWLibrary.Get Device Ip${testfilename},${casename}
Documentation the functions are as follows: acquiring an ip address value after the mobile phone is accessed: return: returning device ip address values
Start/End/Elapsed:20231027 17:59:11.950/20231027 17:59:23.545/00:00:11.595
17:59:23.545 INFO device 9YS0219002012954 is connected to
17:59:23.545 INFO$[phone_ipaddress]=10.2.1.25
Optionally, in the embodiment of the present application, the second sub-key may be, but is not limited to, dl_rate_operation/ul_rate_operation key, and the average flow value is counted by calling the dl_rate_operation/ul_rate_operation key to perform uplink/downlink packet filling operation on the network switching device. The specific calling mode is as follows:
KEYWORD SWLibrary.Phone DI Rate Operate${iperf_time},${thread_number},${iperf_length},${phone_ipaddress},S{linux_url1},${linux_username1},S{linux_pas sword1}00:01:18.958
Documentation the functions are as follows: the mobile phone starts monitoring and receives downlink pouring packets: PARAM IPERF _time: the packing time is as follows: PARAM THREAD number of irrigation threads: PARAM IPERF _length: and (3) packing length: param linux_url: linux server address: param linux_username: the Linux system logs in the user name: param linux_password: linux system login password
Start/End/Elapsed:20231027 17:59:23.560/20231027 18:00:42 518/00:01:18.958 18:00:42.518INFO device 9Y90219002012954 connected
The start of the downstream TCP packet execution by the system starts to execute the downstream TCP packet by the system, and the system starts to execute the downstream TCP packet by the system
Executing a command: iperef-c 10.2.1.25-w 5120k-i 1-t 60-P5-1 1200
And (5) pouring a bag and returning:
/data/user/0/com.nextdoordeveloper.miperf.niperf/files/iperf:ignoring extra argument-
---------------------------------------------------------------
Server listening on TCP port 5001
TCP window size:10.0MByte(WARNING:requested 5.00Myte)
---------------------------------------------------------------
[4]1ocal 10.2.1.25 port 5001 connected with 10.88.6.66 port 56376
[5]local 10.2.1.25 port 5001 comnected with 10.88.6.66 port 56380
[6]local 10.2.1.25 port 5001 comnected with 10.88.6.66 port 56384
[7]local 10.2.1.25 port 5001 comnected with 10.88.6.66 port 56378
[8]local 10.2.1.25 port 5001 comnected with 10.88.6.66 port 56382
[ID]Interval Tranafer Bandwidth
[4]0.0-1.0 sec 2.44MBytes 20.4Mbita/sec
[5]0.0-1.0 sec 1.84MBytes 15.5Mbita/sec
[6]0.0-1.0 sec 3.06Mbytes 25.7Mbita/sec
[7]0.0-1.0 sec 2.84Mytes 23.8Mbits/sec
[8]0.0-1.0 sec 2.42MBytes 20.3Mbits/sec
[SUM]0.0-1.0 sec 12.6MBytes 106Mbits/sec
[4]1.0-2.0 sec 3.83MBytes 32.1Mbits/sec
[5]1.0-2.0 sec 3.25MBytes 27.3Mbits/sec
[8]1.0-2.0 sec 3.80MBytes 31.9Mbits/sec
[6]1.0-2.0 sec 4.37MBytes 36.7Mbits/sec
[7]1.0-2.0 sec 4.08MBytes 34.2Mbits/sec
[SUM]1.0-2.0 sec 19.3MBytes 162Mbits/sec
[6]2.0-3.0 sec 2.97MBytes 24.9Mbits/sec
[5]2.0-3.0 sec 2.62MBytes 22.0Mbits/sec
[7]2.0-3.0 sec 2.78MBytes 23.3Mbits/sec
[8]2.0-3.0 sec 2.78MBytes 23.3Mbits/sec
[4]2.0-3.0 sec 2.81MBytes 23.5Mbits/sec
[SUM]2.0-3.0 sec 13.9MBytes 117Mbits/sec
[4]3.0-4.0 sec 4.65MBytes 39.0Mbits/sec
[5]3.0-4.0 sec 4.77MBytes 40.1Mbits/sec
[6]3.0-4.0 sec 4.62MBytes 38.8Mbits/sec
[7]3.0-4.0 sec 4.96MBytes 41.6Mbits/sec
[8]3.0-4.0 sec 4.62MBytes 38.8Mbits/sec
[SUM]3.0-4.0 sec 23.6MBytes 198Mbits/sec
'425','425','425','421','428','416",'434','423','426","424','415',"434','425',"425','423','424','425','423','424','422','426','424','425','425','423','425','424','424','425','424','406']
the average rate of the downstream packet at the originating end is 405.98Mbits/sec
The following TCP packet execution completion= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
18:00:42.518 INFO [' result5] = average rate of 405.98Mbits/sec for downstream packets on the originating side
Alternatively, in the embodiment of the present application, the third sub-key may be, but is not limited to, a compare_para key, and call the compare_para key to obtain crnti on the base station side and determine whether it is consistent with the ue side. The specific calling mode is as follows:
KEYWORD builin. Comment [ determine whether to acquire CRNTI】000.00:00:00KEYWORD${results},${results_2}=SWLbrary.Get Crnti${linux_uri},${linux_username},${linux_password},${cell_id},${testfilename},${casename}00:00:01.285
Documentation the functions are as follows: obtaining CRNTI information: param linux_url: linux server address: param linux_ usemame: the Linux system logs in the user name: param linux_password: linux system login password: PARAM CELL _id: cell id defaults to 0param testfilename: folder name: PARAM CASENAME: case name: return: return list cmti information
Start/End/Elapsed:20231027 18:00:42.518/20231027 18:00:43.803/00:00:01.28518:00:43.803INFO 192.168.5.111- A file: tmp/cet_crnti.txt=d: SW_ autotest _result_log_ tetae _ 20231027 _174237_40M_301 U_256 qam _4T4R downstream TCP traffic authentication \output\get_ernti.txt, download success [ 'odi: command tine measured:0.000342953sec\n', 'odi:ok (odi-n duapp0 display-ue-info) \n' ]
['UE Crnti:125']
18:00:43.803 INFO${results}=True
18:00:43.803 INFO${results_2}=['125']
KEYWORD${results1}=SWLibrary.Compare Para${val1},${results_2}00000:00:00
Documentation the functions are as follows: judging whether the list is in the list: param value1: character string: param value2: list: retumn: return True or Flase
Start/End/Elapsed:20231027 18:00:43.803/20231027 18:00:43.803/00:00:00.00018:00:43.803 INFO${resultsl}=True
KEYWORD Builtin. Run Key word If "$ (results 1) =" True "=" Log To Console, UE and base station side RNTI are consistent ELSE, log To Console, UE and base station side RNTI are inconsistent 000:00:00.
Optionally, in the embodiment of the present application, the third sub-key may also be a get_ue_rate key, and the third sub-test program is called by calling the third sub-key to obtain the flow of the ue level of the base station, and the average flow is counted. The specific calling mode is as follows:
KEYWORD$(resul6),$(result6-1)=SWLibrary.Get Ue Rate$(rate_mode),$(linux_url),$(linux_username),$(linux_password),$(cell_id),$(line_cnt),$(testfilenam e),$(casename),$(crnti_list)00.00.01.214
Documentation the functions are as follows: acquiring uplink and downlink flow and calculating average flow: PARAM RATE _mode: rate mode, e.g. dV/ul: param linux_urt: linux server address: the param linux-usemameLinux system logs in the user name: param linux_password Linux system login password: PARAM CELL _id: cell id defaults to 0: PARAM LINE _cnt: number of rows PARAM TESTFLENAME: folder name PARAM CASENAME: case name: retumn return rate average
Start/End/Elapsed:20231027 19:01:34.802/20231027 19:01:36.016/00:00:01.214 19:01:36.016INFO odi-n duappo show-ue-throughput-count 125 100>/tmp/tmp_throughoutput_info.txt
192.168.5.111-Document :/tmp/tmp_throughoutput_info.txt=>D:\SW_autotest\result\log\testeare_20231027_174237\40M_3010_256qam_4T4R difference downstream TCP service authentication/output/tmp_ throughoutput _info.txt, successful download ['odi:dest processor is:192.168.4.1\n','\n','Dispalying Crnti:125\n','MAC throughput from the oldest second to last full second\n','Histogram size is:301\n','last s:\t DL tput(Mbps[MAC/RLC]:RBs(slice0"3)/Times:D1Bler(ACK:NACK:DTX)AvgMcs[AvgCQI]:AvgLayers:UdpSdu/AllSdu)\t\t UL tput(Mbps[MAC/RLC/PADDING]:RBs(slice0"3)/Times:ulBler(CrcError:CrcDtx):AvgMcs:AvgLayers:Rssi(U1Simrl:U1Sinx2))\n','100:\t 0.00/0.00(0(:0.00%(0:0:0):0.00[14.92]:0.00[2.00]:0/0)\t 0.00/0.00/0.00(0:00/(0/0/0/0)/0:0.00%:(0:0):0.00:0.00:-127.50(0.00:0.00))\n','99:\t0.00/0.006(:0.00%(0:0:0):0.00[14.84]:0.00[2.00]:0/0)\t 0.00/0.00/0.00(0:0 0/(0/0/0/0)/0:0.00%:(0:0):0.00:0.00:-127.50(0.00:0.00))\n','98:\t0.00/0.00(:0.00%(0:0:0):0.00[15.00]:0.00[2.00]:0/0)\t 0.00/0.00/0.00(0:0 0/(0/0/0/0)/0:0.00%:(0:0
......
['7:\t316.74']
['6:\t116.55']
['105.81','284.98','310.55','308.02','305.98','305.16','308.20','304.92','309.22','304.75','315.56','308.82','303.99','305.55','306.61','310.20','309.06','307.91','311.84','307.13','306.36','305.37','311.51','311.58','306.85','305.15','304.95','303.89','305.54','307.83','305.37','305.10','313.26','307.34','305.29','304.75','310.60','306.52','309.73','307.38','307.22','304.13','305.47','307.73','305,88','307.94','305.29','307.71','307.25','305.37','305.36','307.16','306.84','305.92','309.33','305.10','306.21','307.08','304.75','316.74','116.55']
315.56
The average rate of the downlink of the MAC layer at the cell level of the base station is 307.11Mbits, and the maximum rate is 315.56Mbits.
19:01:36.016 INFO${result6}=307.11
19:01:36.016 INFO${result6-1}=315.56
Optionally, in the embodiment of the present application, a fourth sub-keyword may be configured in the target test case, where the fourth sub-keyword may be, but is not limited to, should be equal keywords, and the fourth sub-test program is called by calling should be equal keywords to determine whether the average flow accords with the expected value. The specific calling mode is as follows:
KEYWORD Builtin. Run Key word If $ { result6} > = $ { rate_config }, log To Console, average flow and peak flow meet expectations, ELSE, log To Console, average flow and peak flow do not meet expectations-! ! !000 00 00:00
Documentation:Runs the given keyword with the given arguments,if condition is tue.
Start/End/Elapsed:20231027 19:01:36.031/20231027 19:01:36.031/00:00:00.000
KEYWORD building ton.log To Console average flow and peak flow meet the expected 000:00:00:00
As an optional embodiment, the configuring the target test program for the service item includes:
Calling an initial test script corresponding to the service item, wherein universal test logic used when testing corresponding test conditions are carried out on the service item is recorded in the initial test script;
And inputting the test variable indicated by the test requirement into the initial test script to obtain a target test script, wherein the target test program comprises the target test script.
Optionally, in the embodiment of the present application, the initial test script may be a script that is acquired from a plurality of preset scripts and matches with a service item, where the plurality of preset scripts are test scripts configured for the service item that the network interaction device has, and the scheme is not limited to this.
As an optional embodiment, the constructing the target test case of the network switching device according to the item attribute of the service item includes:
in case the number of the service items is plural, determining a test order of the plurality of the service items according to the item attribute,
And ordering the item keywords of each of the plurality of business items according to the test sequence to obtain a keyword sequence, wherein the keyword sequence is recorded in the target test case, and each item keyword is used for indicating the storage position of the target test program of the corresponding business item.
Optionally, in the embodiment of the present application, the method for determining the test sequence may be to determine the item attribute of the plurality of service items, determine the target test sequence corresponding to each item attribute from the corresponding relationship between the item attribute having a corresponding relationship with the test sequence for the network switching device, and sort the plurality of service items by using the target test sequence to obtain the test sequence.
As an optional embodiment, after the calling the target test program according to the target test case to test the network switching device to obtain a target test result, the method further includes:
generating a target notification message carrying the target test result;
and sending the target notification message to a target account corresponding to the network switching equipment, wherein the target account is used for performing performance maintenance on the network switching equipment according to the target test result.
From the description of the above embodiments, it will be clear to a person skilled in the art that the method according to the above embodiments may be implemented by means of software and a necessary general hardware platform, but of course also by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method of the various embodiments of the present application.
Fig. 6 is a block diagram of a test apparatus of a network switching device according to an embodiment of the present application; as shown in fig. 6, includes: the receiving module is used for receiving a target test request for the network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
the response module is used for responding to the target test request and analyzing service items required to be tested by the target test requirement;
the processing module is used for configuring a target test program for the service item and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein the target test program records test logic for testing the service item, and the target test case records test time sequence for testing the service item of the network switching equipment by using the target test program;
and the test module is used for calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
Through the above, the service item of the network switching equipment requested by the target test request is determined by analyzing the target test requirement indicated by the received target test request, the corresponding target test program is configured for the service item, and the target test case for indicating the test time sequence for testing the service item of the network switching equipment by using the target test program is constructed according to the item attribute of the service item, so that the target test case can be used for calling the target test program when the test is performed, the network switching equipment is tested according to the target test requirement, and the complex operation of manual test by a tester and the test fault caused by unskilled test service in the related art are avoided. By adopting the technical scheme, the problem of lower testing efficiency of the network switching equipment in the related technology is solved, and the technical effect of improving the testing efficiency of the network switching equipment is achieved.
Optionally, the test module includes:
The system comprises an acquisition unit, a storage unit and a storage unit, wherein the acquisition unit is used for acquiring keyword sequences of a plurality of item keywords of a plurality of service items to be tested, wherein each item keyword is used for indicating the storage position of the target test program of the corresponding service item, and the keyword sequences are recorded in the target test case;
And the testing unit is used for calling the item keywords according to the keyword sequence to test the network switching equipment.
Optionally, the test unit is configured to:
calling a first test program by using a first keyword, wherein the first test program is used for enabling the running state of the network switching equipment to be changed;
under the condition that the running state of the network switching equipment is regulated to be the running state for executing equipment performance test, a second keyword is used for calling a second test program to test file updating performance of the network switching equipment, wherein the second test program is used for sending a network configuration file to be updated to the network switching equipment, detecting an updating result of the network switching equipment on the network configuration file, and recording data used by the network switching equipment when carrying out data transmission service in the network configuration file;
under the condition that the second test program is determined to be operated, a third key word is used for calling a third test program to test the restarting performance of the network switching equipment, wherein the third test program is used for controlling the network switching equipment to execute equipment restarting operation;
Under the condition that the third test program is determined to be operated, a fourth keyword is used for calling a fourth test program to test the data transmission capacity of the network switching equipment under different signal strengths, wherein the fourth test program is used for adjusting the attenuation value of a signal attenuator to a signal transmitted to the network switching equipment;
Under the condition that the fourth test program is determined to be operated, a fifth test program is called by using a fifth keyword to perform user equipment access test on the network switching equipment, wherein the fifth test program is used for controlling the network switching equipment to execute user equipment access operation;
And under the condition that the network switching equipment is accessed with target user equipment, a sixth keyword is used for calling a sixth test program to perform data transmission test on the network switching equipment, wherein the sixth test program is used for controlling the network switching equipment to perform data exchange with the target user equipment, the project keywords comprise the first keyword, the second keyword, the third keyword, the fourth keyword, the fifth keyword and the sixth keyword, and the target test program comprises the first test program, the second test program, the third test program, the fourth test program, the fifth test program and the sixth test program.
Optionally, the test unit is further configured to:
A first sub-test program is called by using a first sub-keyword to execute a parameter acquisition test on the network switching equipment, wherein the first sub-test program is used for controlling the network switching equipment to acquire data transmission parameters from the target user equipment, and the data transmission parameters are used for indicating a transmission mode of parameter transmission between the network switching equipment and the target user equipment;
under the condition that the running of the first sub-test program is determined to be finished, a second sub-test program is called by using a second sub-keyword to perform a packet filling test on the network switching equipment, wherein the second sub-test program is used for controlling the transmission of data packets between the network switching equipment and the target user equipment by using the data transmission parameters;
And calling a third sub-test program to collect test results of the pack test by using a third sub-keyword, wherein the third sub-test program is used for collecting data transmission parameters between the network switching equipment and the target user equipment, the sixth keyword comprises the first sub-keyword, the second sub-keyword and the third sub-keyword, and the sixth test program comprises the first sub-test program, the second sub-test program and the third sub-test program.
Optionally, the processing module includes:
The calling unit is used for calling an initial test script corresponding to the service item, wherein the initial test script records general test logic used when testing corresponding test conditions of the service item;
and the input unit is used for inputting the test variable indicated by the test requirement into the initial test script to obtain a target test script, wherein the target test program comprises the target test script.
Optionally, the processing module includes:
A determining unit for determining a test sequence of a plurality of the business items according to the item attribute in the case that the number of the business items is a plurality,
The ordering unit is used for ordering the item keywords of each of the plurality of business items according to the testing sequence to obtain a keyword sequence, wherein the keyword sequence is recorded in the target test case, and each item keyword is used for indicating the storage position of the target test program of the corresponding business item.
Optionally, the apparatus further includes:
The generation module is used for generating a target notification message carrying the target test result after the target test result is obtained by calling the target test program according to the target test case to test the network switching equipment;
And the sending module is used for sending the target notification message to a target account corresponding to the network switching equipment, wherein the target account is used for performing performance maintenance on the network switching equipment according to the target test result.
An embodiment of the application also provides an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of the test method embodiment of any of the above described network switching apparatuses.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, where the transmission device is connected to the processor, and the input/output device is connected to the processor.
Alternatively, in the present embodiment, the above-described processor may be configured to execute the following steps by a computer program: receiving a target test request for network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
responding to the target test request, and analyzing service items required to be tested by the target test requirement;
configuring a target test program for the service item, and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein test logic for testing the service item is recorded in the target test program, and a test time sequence for testing the service item of the network switching equipment by using the target test program is recorded in the target test case;
and calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
Embodiments of the application also provide a computer program product comprising a computer program which, when executed by a processor, implements the steps of any of the method embodiments described above.
Embodiments of the present application also provide another computer program product comprising a non-volatile computer readable storage medium storing a computer program which, when executed by a processor, implements the steps of any of the method embodiments described above.
Embodiments of the present application also provide a computer program comprising computer instructions stored on a computer readable storage medium; the processor of the computer device reads the computer instructions from the computer readable storage medium and the embedder executes the computer instructions to cause the computer device to perform the steps of any of the method embodiments described above.
Alternatively, in the present embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory RAM), a removable hard disk, a magnetic disk, or an optical disk, etc., which can store program codes.
Alternatively, specific examples in this embodiment may refer to examples described in the foregoing embodiments and optional implementations, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the application described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may alternatively be implemented in program code executable by computing devices, so that they may be stored in a memory device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps within them may be fabricated into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
The foregoing is merely a preferred embodiment of the present application and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present application, which are intended to be comprehended within the scope of the present application.

Claims (10)

1. A method for testing network switching equipment, comprising:
receiving a target test request for network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
responding to the target test request, and analyzing service items required to be tested by the target test requirement;
configuring a target test program for the service item, and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein test logic for testing the service item is recorded in the target test program, and a test time sequence for testing the service item of the network switching equipment by using the target test program is recorded in the target test case;
and calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
2. The method of claim 1, wherein the invoking the target test program to test the network switching device according to the target test case comprises:
Acquiring keyword sequences of a plurality of item keywords of a plurality of business items to be tested, wherein each item keyword is used for indicating a storage position of the target test program of the corresponding business item, and the keyword sequences are recorded in the target test case;
and calling the item keywords according to the keyword sequence to test the network switching equipment.
3. The method of claim 2, wherein said invoking the item key in accordance with the key sequence tests the network switching device, comprising:
calling a first test program by using a first keyword, wherein the first test program is used for enabling the running state of the network switching equipment to be changed;
under the condition that the running state of the network switching equipment is regulated to be the running state for executing equipment performance test, a second keyword is used for calling a second test program to test file updating performance of the network switching equipment, wherein the second test program is used for sending a network configuration file to be updated to the network switching equipment, detecting an updating result of the network switching equipment on the network configuration file, and recording data used by the network switching equipment when carrying out data transmission service in the network configuration file;
under the condition that the second test program is determined to be operated, a third key word is used for calling a third test program to test the restarting performance of the network switching equipment, wherein the third test program is used for controlling the network switching equipment to execute equipment restarting operation;
Under the condition that the third test program is determined to be operated, a fourth keyword is used for calling a fourth test program to test the data transmission capacity of the network switching equipment under different signal strengths, wherein the fourth test program is used for adjusting the attenuation value of a signal attenuator to a signal transmitted to the network switching equipment;
Under the condition that the fourth test program is determined to be operated, a fifth test program is called by using a fifth keyword to perform user equipment access test on the network switching equipment, wherein the fifth test program is used for controlling the network switching equipment to execute user equipment access operation;
And under the condition that the network switching equipment is accessed with target user equipment, a sixth keyword is used for calling a sixth test program to perform data transmission test on the network switching equipment, wherein the sixth test program is used for controlling the network switching equipment to perform data exchange with the target user equipment, the project keywords comprise the first keyword, the second keyword, the third keyword, the fourth keyword, the fifth keyword and the sixth keyword, and the target test program comprises the first test program, the second test program, the third test program, the fourth test program, the fifth test program and the sixth test program.
4. A method according to claim 3, wherein said invoking a sixth test procedure using a sixth key to perform a data transfer test on said network switching device comprises:
A first sub-test program is called by using a first sub-keyword to execute a parameter acquisition test on the network switching equipment, wherein the first sub-test program is used for controlling the network switching equipment to acquire data transmission parameters from the target user equipment, and the data transmission parameters are used for indicating a transmission mode of parameter transmission between the network switching equipment and the target user equipment;
under the condition that the running of the first sub-test program is determined to be finished, a second sub-test program is called by using a second sub-keyword to perform a packet filling test on the network switching equipment, wherein the second sub-test program is used for controlling the transmission of data packets between the network switching equipment and the target user equipment by using the data transmission parameters;
And calling a third sub-test program to collect test results of the pack test by using a third sub-keyword, wherein the third sub-test program is used for collecting data transmission parameters between the network switching equipment and the target user equipment, the sixth keyword comprises the first sub-keyword, the second sub-keyword and the third sub-keyword, and the sixth test program comprises the first sub-test program, the second sub-test program and the third sub-test program.
5. The method of claim 1, wherein configuring the targeted test program for the business project comprises:
Calling an initial test script corresponding to the service item, wherein universal test logic used when testing corresponding test conditions are carried out on the service item is recorded in the initial test script;
And inputting the test variable indicated by the test requirement into the initial test script to obtain a target test script, wherein the target test program comprises the target test script.
6. The method of claim 1, wherein constructing the target test case for the network switching device according to the item attribute of the service item comprises:
determining a testing sequence of a plurality of business items according to the item attribute under the condition that the number of the business items is a plurality of;
And ordering the item keywords of each of the plurality of business items according to the test sequence to obtain a keyword sequence, wherein the keyword sequence is recorded in the target test case, and each item keyword is used for indicating the storage position of the target test program of the corresponding business item.
7. The method according to claim 1, wherein after the target test program is called according to the target test case to test the network switching device, the method further comprises:
generating a target notification message carrying the target test result;
and sending the target notification message to a target account corresponding to the network switching equipment, wherein the target account is used for performing performance maintenance on the network switching equipment according to the target test result.
8. A test apparatus for a network switching device, comprising:
The receiving module is used for receiving a target test request for the network switching equipment, wherein the target test request is used for indicating to test the equipment performance of the network switching equipment according to target test requirements;
the response module is used for responding to the target test request and analyzing service items required to be tested by the target test requirement;
the processing module is used for configuring a target test program for the service item and constructing a target test case of the network switching equipment according to the item attribute of the service item, wherein the target test program records test logic for testing the service item, and the target test case records test time sequence for testing the service item of the network switching equipment by using the target test program;
and the test module is used for calling the target test program according to the target test case to test the network switching equipment to obtain a target test result.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein the program when run performs the method of any one of claims 1 to 7.
10. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method according to any of claims 1 to 7 by means of the computer program.
CN202410434783.8A 2024-04-10 2024-04-10 Method and device for testing network switching equipment, storage medium and electronic device Pending CN118075169A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410434783.8A CN118075169A (en) 2024-04-10 2024-04-10 Method and device for testing network switching equipment, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410434783.8A CN118075169A (en) 2024-04-10 2024-04-10 Method and device for testing network switching equipment, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN118075169A true CN118075169A (en) 2024-05-24

Family

ID=91097499

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410434783.8A Pending CN118075169A (en) 2024-04-10 2024-04-10 Method and device for testing network switching equipment, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN118075169A (en)

Similar Documents

Publication Publication Date Title
US20220158926A1 (en) Active assurance for virtualized services
CN109218139B (en) Gateway test system
EP3420681A1 (en) Cloud verification and test automation
CN103812726A (en) Automated testing method and device for data communication equipment
CN105052076B (en) Network element management system and network element management method based on cloud computing
CN112732572A (en) Service testing method, device and system, storage medium and electronic device
CN106792784B (en) A kind of method, server and system carrying out data check in server side
CN114390578A (en) Network performance testing method and device, electronic equipment and medium
CN113946559A (en) Data processing method, target database system and data processing system
CN111479287A (en) Simulation test method, device, equipment and storage medium for core network of non-independent networking
US11533247B2 (en) Methods, systems, and computer readable media for autonomous network test case generation
WO2017016386A1 (en) Method and device for implementing radio remote unit fault analysis
CN110972185A (en) Data transmission method and device
CN118075169A (en) Method and device for testing network switching equipment, storage medium and electronic device
CN114826979B (en) Network link quality acquisition method, device, system, equipment and storage medium
CN114024598B (en) Forwarding interface test method and device
US11716241B1 (en) Methods, systems, and computer readable media for actively diagnosing and remediating performance degradation in a production network
CN112612673B (en) Analysis method and device for dial testing log, storage medium and electronic device
EP2630750A1 (en) Quality of service monitoring device and method of monitoring quality of service
CN113032054A (en) Service execution method, device, storage medium and electronic device
CN114461501A (en) Resource abnormality detection method and device, storage medium, and electronic device
CN114090074A (en) Method and device for configuring operating environment, storage medium and electronic device
CN115391127A (en) Dial testing method and device, storage medium and chip
Díaz-Zayas et al. Remote control and instrumentation of Android devices
Bianchi et al. One size hardly fits all: towards context-specific wireless mac protocol deployment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination