Equipment testing method, device, computer system and readable storage medium

By creating virtual machines in test equipment and using virtual network adapters, the high cost and low efficiency of the automotive center console is solved, and multiple on-board smart boxes are achieved simultaneous testing, improving testing efficiency and reducing costs.

CN113157500BActive Publication Date: 2024-11-12ALIBABA GROUP HOLDING LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010076764.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-01-23
Publication Date
2024-11-12
Estimated Expiration
2040-01-23

AI Technical Summary

Technical Problem

The procurement and maintenance cost of the automotive center console is high and the area occupies a large area. A center console can only be connected to one car smart box, which has low testing efficiency and seriously affects production capacity.

Method used

Create a virtual machine in the test device, transfer instructions and data between the virtual machine and the device to be tested, and realize simultaneous testing of multiple vehicle-mounted smart boxes. Use virtual network adapter and MirrorLink protocol for data transmission and display, simulating multiple devices Independent testing environment.

Benefits of technology

It reduces testing costs, improves testing efficiency, and realizes that a test device tests multiple on-board smart boxes at the same time, simplifies the testing process and equipment configuration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113157500B_ABST
    Figure CN113157500B_ABST
Patent Text Reader

Abstract

The embodiments of the present disclosure disclose a device testing method, apparatus, computer system and readable storage medium. The device testing method includes: creating a virtual machine for a device under test in a test device; transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a device testing method, apparatus, computer system, and readable storage medium. Background Art

[0002] The in-vehicle smart box is connected to the car's center console to complete map navigation, intelligent voice control, online music on demand and other functions. During the production process of the in-vehicle smart box, a period of stability testing is required. In the traditional testing method, an in-vehicle smart box needs to be connected to a car's center console for screen projection testing.

[0003] In the process of proposing the present disclosure, the inventor found that the purchase and maintenance costs of the car center console are high, the occupied area is large, and one car center console can only be connected to one car smart box, the test efficiency is low, and the production capacity is seriously affected. Therefore, it is necessary to design a test tool to replace the car center console, so as to reduce the test cost and improve the test efficiency. Summary of the invention

[0004] In order to at least partially solve the related technical problems, the embodiments of the present disclosure provide a device testing method, apparatus, computer system and readable storage medium.

[0005] In a first aspect, an embodiment of the present disclosure provides a device testing method.

[0006] Specifically, the device testing method includes: creating a virtual machine for the device to be tested in the testing device;

[0007] Instructions and / or data are transmitted between the testing device and the device under test through the virtual machine to test the device under test.

[0008] In combination with the first aspect, in a first implementation of the first aspect of the present disclosure, creating a virtual machine for the device under test in the test device includes creating multiple virtual machines running in parallel in the test device for multiple devices under test connected to the test device.

[0009] In combination with the first aspect, in a second implementation of the first aspect of the present disclosure, the device testing method further includes: generating a virtual network adapter for the device under test in the testing device;

[0010] Receiving a logical address allocated by the device under test to the virtual network adapter;

[0011] The physical address of the virtual network adapter is bound to the logical address through the virtual machine.

[0012] In combination with the first aspect, in a third implementation of the first aspect of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes:

[0013] Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or

[0014] The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

[0015] In combination with the third implementation manner of the first aspect, in a fourth implementation manner of the first aspect of the present disclosure, the incoming data includes display data of the device under test;

[0016] The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

[0017] In combination with the fourth implementation of the first aspect, in a fifth implementation of the first aspect of the present disclosure, displaying an image corresponding to the display data by the virtual machine includes:

[0018] In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines;

[0019] In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

[0020] In combination with the fourth implementation manner of the first aspect, in a sixth implementation manner of the first aspect of the present disclosure, displaying an image corresponding to the display data by the virtual machine includes:

[0021] Creating a web page based on the display data by the virtual machine;

[0022] The web page is displayed.

[0023] In combination with the third implementation manner of the first aspect, in a seventh implementation manner of the first aspect of the present disclosure, the receiving user input through the virtual machine includes:

[0024] The virtual machine receives input from a user on a web page of the test device.

[0025] In combination with the first aspect, in the eighth implementation method of the first aspect of the present disclosure, the creating a virtual machine for the device under test in the test device includes: when detecting a device under test connected to the test device through a universal serial bus interface, creating a virtual machine in the test device for the connected device under test.

[0026] In combination with the first aspect, in a ninth implementation of the first aspect of the present disclosure, the step of creating a virtual machine for the device under test in the test device includes: creating corresponding multiple virtual machines for the multiple devices under test, each virtual machine running a corresponding guest system in the test device.

[0027] In a second aspect, an equipment testing device is provided in an embodiment of the present disclosure.

[0028] Specifically, the equipment testing device comprises:

[0029] A virtual machine creation module, used to create a virtual machine for the device under test in the test device;

[0030] The instruction and data transmission module is used to transmit instructions and / or data between the test device and the device under test through the virtual machine to test the device under test.

[0031] In combination with the second aspect, in a first implementation manner of the second aspect of the present disclosure, creating a virtual machine for the device under test in the test device includes creating multiple virtual machines running in parallel in the test device for multiple devices under test connected to the test device.

[0032] In combination with the second aspect, in a second implementation of the second aspect of the present disclosure, the device testing apparatus further includes: a virtual network adapter generation module, configured to generate a virtual network adapter for the device under test in the test device;

[0033] A logical address receiving module, used for receiving the logical address allocated by the device under test to the virtual network adapter;

[0034] The address binding module is used to bind the physical address of the virtual network adapter to the logical address through the virtual machine.

[0035] In combination with the second aspect, in a third implementation of the second aspect of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes:

[0036] Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or

[0037] The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

[0038] In combination with the third implementation manner of the second aspect, in a fourth implementation manner of the second aspect of the present disclosure, the incoming data includes display data of the device under test;

[0039] The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

[0040] In combination with the fourth implementation manner of the second aspect, in a fifth implementation manner of the second aspect of the present disclosure, displaying an image corresponding to the display data by the virtual machine includes:

[0041] In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines;

[0042] In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

[0043] In combination with the fourth implementation manner of the second aspect, in a sixth implementation manner of the second aspect of the present disclosure, displaying an image corresponding to the display data by the virtual machine includes:

[0044] Creating a web page based on the display data by the virtual machine;

[0045] The web page is displayed.

[0046] In combination with the third implementation manner of the second aspect, in a seventh implementation manner of the second aspect of the present disclosure, the receiving user input through the virtual machine includes:

[0047] The virtual machine receives input from a user on a web page of the test device.

[0048] In combination with the second aspect, in the eighth implementation method of the second aspect of the present disclosure, the creating a virtual machine for the device under test in the test device includes: when detecting a device under test connected to the test device through a universal serial bus interface, creating a virtual machine in the test device for the connected device under test.

[0049] In combination with the second aspect, in a ninth implementation of the second aspect of the present disclosure, the step of creating a virtual machine for the device under test in the test device comprises: creating corresponding multiple virtual machines for the multiple devices under test, each virtual machine running a corresponding guest system in the test device.

[0050] In a third aspect, a computer system is provided in an embodiment of the present disclosure. Specifically, the computer system includes: a processor; a memory storing executable instructions, and when the executable instructions are executed by the processor, the following method steps are implemented: creating a virtual machine for the device under test in the test device;

[0051] Instructions and / or data are transmitted between the testing device and the device under test through the virtual machine to test the device under test.

[0052] In combination with the third aspect, in a first implementation of the third aspect of the present disclosure, creating a virtual machine for the device under test in the test device includes creating multiple virtual machines running in parallel in the test device for multiple devices under test connected to the test device.

[0053] In combination with the third aspect, in a second implementation of the third aspect of the present disclosure, the method steps further include: generating a virtual network adapter for the device under test in the test device;

[0054] Receiving a logical address allocated by the device under test to the virtual network adapter;

[0055] The physical address of the virtual network adapter is bound to the logical address through the virtual machine.

[0056] In combination with the third aspect, in a third implementation of the third aspect of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes:

[0057] Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or

[0058] The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

[0059] In combination with the third implementation of the third aspect, in a fourth implementation of the third aspect of the present disclosure, the incoming data includes display data of the device under test;

[0060] The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

[0061] In combination with the fourth implementation of the third aspect, in a fifth implementation of the third aspect of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes:

[0062] In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines;

[0063] In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

[0064] In combination with the fourth implementation manner of the third aspect, in a sixth implementation manner of the third aspect of the present disclosure, displaying an image corresponding to the display data by the virtual machine includes:

[0065] Creating a web page based on the display data by the virtual machine;

[0066] The web page is displayed.

[0067] In combination with the third implementation of the third aspect, in a seventh implementation of the third aspect of the present disclosure, the receiving user input through the virtual machine includes:

[0068] The virtual machine receives input from a user on a web page of the test device.

[0069] In combination with the third aspect, in the eighth implementation method of the third aspect of the present disclosure, the creating a virtual machine for the device under test in the test device includes: when detecting a device under test connected to the test device through a universal serial bus interface, creating a virtual machine in the test device for the connected device under test.

[0070] In combination with the third aspect, in a ninth implementation of the third aspect of the present disclosure, the step of creating a virtual machine for the device under test in the test device comprises: creating corresponding multiple virtual machines for the multiple devices under test, each virtual machine running a corresponding guest system in the test device.

[0071] In a fourth aspect, a computer-readable storage medium is provided in an embodiment of the present disclosure.

[0072] Specifically, the computer-readable storage medium stores executable instructions. When the executable instructions are executed by the processor, the method described in any one of the first aspect, the first implementation manner of the first aspect to the seventh implementation manner of the first aspect is implemented.

[0073] According to the embodiments of the present disclosure, by creating a virtual machine for a device under test in a test device, multiple devices under test can be tested simultaneously by one test device, thereby improving test efficiency and reducing test complexity and cost. BRIEF DESCRIPTION OF THE DRAWINGS

[0074] Other objects and advantages of the present disclosure will become more apparent through the following detailed description of non-limiting embodiments in conjunction with the accompanying drawings. In the accompanying drawings:

[0075] Figure 1 A schematic diagram of application scenario 1 according to an embodiment of the present disclosure is shown;

[0076] Figure 2A A schematic diagram of application scenario 2 according to an embodiment of the present disclosure is shown;

[0077] Figure 2B A schematic diagram showing a first display mode according to an embodiment of the present disclosure;

[0078] Figure 2C A schematic diagram showing a second display mode according to an embodiment of the present disclosure;

[0079] Figure 3 A flow chart of a device testing method according to an embodiment of the present disclosure is shown;

[0080] Figure 4 A block diagram of a device testing apparatus according to an embodiment of the present disclosure is shown;

[0081] Figure 5 A block diagram of a device testing apparatus according to an embodiment of the present disclosure is shown;

[0082] Figure 6 A structural block diagram of a computer system according to an embodiment of the present disclosure is shown;

[0083] Figure 7 A structural block diagram showing a computer system architecture suitable for a device testing method according to an embodiment of the present disclosure. DETAILED DESCRIPTION

[0084] Hereinafter, exemplary embodiments of the present disclosure will be described in detail with reference to the accompanying drawings so that those skilled in the art can easily implement them. In addition, for the sake of clarity, parts not related to the description of the exemplary embodiments are omitted in the accompanying drawings.

[0085] In the present disclosure, it should be understood that terms such as "include" or "have" are intended to indicate the presence of features, numbers, steps, behaviors, components, parts, or a combination thereof disclosed in the present specification, and are not intended to exclude the possibility that one or more other features, numbers, steps, behaviors, components, parts, or a combination thereof exist or are added.

[0086] It should also be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present disclosure may be combined with each other. The present disclosure will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0087] In the process of proposing the present disclosure, the inventor found that the purchase and maintenance costs of the car center console are high, the occupied area is large, and one car center console can only be connected to one car smart box, the test efficiency is low, and the production capacity is seriously affected. It is necessary to design a test tool to replace the car center console, so as to reduce costs and improve test efficiency.

[0088] Figure 1 The schematic diagram of application scenario 1 according to the embodiment of the present disclosure is shown, and specifically the structural block diagram of the test host for testing the vehicle-mounted smart box is shown. It can be understood that Figure 1 The application scenarios shown are only for illustrating the concepts and principles of the present disclosure, and do not mean that the present disclosure is only applicable to such application scenarios.

[0089] According to the embodiment of the present disclosure, a test host is used instead of a car center console, and multiple vehicle-mounted smart boxes are connected to the test host, so that multiple vehicle-mounted smart boxes can be tested at the same time.

[0090] like Figure 1 As shown, the test host includes a host server 101 and a host interface 102. The host server 101 is used to provide various test-related services, and the host interface 102 is used for interaction between the test host and the tester.

[0091] In the host server 101, the USB (Universal Serial Bus) device enumeration module 104 detects the in-vehicle smart box connected through the USB interface. After detecting the newly connected in-vehicle smart box, the virtual machine management module 105 establishes a virtual machine image 103. The virtual machine image 103 includes: a MirrorLink client 109, which is used to communicate with the in-vehicle smart box through the MirrorLink protocol; an rtsp service 110, which uses rtsp (Real Time Streaming Protocol) to transmit the display data of the in-vehicle smart box to the host interface; and a WebSocket service 111, which is used to receive the operation instructions of the tester.

[0092] MirrorLink is a "vehicle networking" standard jointly initiated and established by some internationally renowned mobile phone manufacturers and automobile manufacturers, aiming to standardize the effective connection between smartphones and vehicle systems and form a good user experience. When this standard is used for mobile phone and vehicle interconnection, two-way control of mobile phones and vehicle systems for specific application software can be achieved. The goal is to enable users to control their mobile phones with physical buttons or voice commands on the vehicle without looking at the mobile phone screen, touching the mobile phone screen or operating the mobile phone buttons during driving, including answering / making calls, listening to mobile phone music, using mobile phone navigation, etc. According to the embodiment of the present disclosure, the device list page 112 and the device display page 113 can be implemented through web pages. The device list page 112 queries the vehicle smart box device list and the corresponding rtsp address through the http service 106 and the virtual machine management module 105. The virtual machine management module 105 returns the vehicle smart box device list and the corresponding rtsp address to the http service 106. After the http service 106 converts the car smart box list, it is sent to the device list page 112. Then, the device list page 112 requests the rtsp stream from the rtsp service 110, and the rtsp service 110 sends the display data and / or audio data of the vehicle-mounted smart box received through the MirrorLink client 109 to the rtsp forwarding service 108, and the rtsp forwarding service 108 pushes the display data and audio data to the mp4 (Moving Picture Experts Group-4, Dynamic Picture Experts Group-4) compositer 107, and after composited into an mp4 data stream, the mp4 data stream is sent to the device list page 112 in the host interface 102. The mp4 data stream composited by the mp4 compositer 107 can also be used as a test record file to record the display data and audio data generated by the vehicle-mounted smart box during the test. In the device list page 112, the image screens of multiple vehicle-mounted smart boxes can be displayed simultaneously in the form of thumbnail images. When the tester selects the thumbnail of a specific vehicle-mounted smart box in the device list page 112, the device display page 113 requests the virtual machine management module 105 through the http service 106 to obtain the URL of the device screen of the specific vehicle-mounted box. The virtual machine management module 105 sends the rtsp URL address and websocket address corresponding to the vehicle-mounted smart box to the device display page 113 through the http service 106. Then, the device display page 113 requests the rtsp stream from the rtsp service 110, obtains the complete image of the specific vehicle-mounted smart box from the rtsp service 110 via the rtsp forwarding service 108, and displays the complete image of the specific vehicle-mounted smart box in full screen mode.The tester can perform input operations in the device display page 113, and the operation instructions (such as the coordinates of the click) are transmitted to the WebSocket service 111 through the WebSocket service address, and transmitted to the in-vehicle smart box through the MirrorLink client 109.

[0093] According to the embodiments of the present disclosure, by creating a virtual machine for each in-vehicle smart box to be tested in a test host, one test host can test multiple in-vehicle smart boxes at the same time. The test host can be implemented using a general-purpose computer or an embedded device, which significantly reduces the test cost and improves the test efficiency compared to the existing technology.

[0094] Figure 2A A schematic diagram of application scenario 2 according to an embodiment of the present disclosure is shown.

[0095] like Figure 2A As shown, the test host 201 can be connected to multiple vehicle-mounted smart boxes at the same time to test the multiple vehicle-mounted smart boxes. Figure 2A It is shown that three in-vehicle smart boxes 202-1, 202-2, and 202-3 are connected to the test host 201 via USB cables. According to the embodiment of the present disclosure, the devices that can be tested simultaneously by the test host 201 are not limited to the in-vehicle smart boxes, and the number of devices tested simultaneously is not limited to three.

[0096] Figure 2B A schematic diagram of a first display mode according to an embodiment of the present disclosure is shown.

[0097] like Figure 2B As shown, the first display mode of the test host, i.e., the thumbnail display mode, can simultaneously display images of multiple in-vehicle smart boxes under test, such as the desktop of the in-vehicle smart box, the application interface of the in-vehicle smart box, the video being played by the in-vehicle smart box, the map navigation screen of the in-vehicle smart box, etc. The images of the in-vehicle smart box are displayed in thumbnail form, and the number of pixels and resolution are lower than Figure 2C The complete image of the second display mode in the test host is displayed. On the screen 203 of the test host, images 204-1, 204-2, and 204-3 of the three tested vehicle-mounted smart boxes are displayed simultaneously. In the first display mode, the images of all tested vehicle-mounted smart boxes are displayed simultaneously, so that the status of each vehicle-mounted smart box can be summarized, and it can be quickly found whether all tested vehicle-mounted smart boxes are working properly, and it can be easily switched to any tested vehicle-mounted smart box.

[0098] Figure 2C A schematic diagram of a second display mode according to an embodiment of the present disclosure is shown.

[0099] like Figure 2CAs shown, the second display mode of the test host, that is, the full display mode, can display the image of the specific vehicle-mounted smart box selected by the tester for interactive testing. Figure 2B When a thumbnail image of any in-vehicle smart box is displayed, the display mode is switched from the first display mode to the second display mode. In the second display mode, the full image of the specific in-vehicle smart box is displayed. The tester can perform input operations on the full image. For example, the tester can operate in the navigation map area 206 and the alternative song area 207 displayed on the screen 205 of the test host, such as selecting a destination navigation point or selecting a song to be played, so as to interactively test the selected specific in-vehicle smart box.

[0100] Figure 3 A flow chart of a device testing method according to an embodiment of the present disclosure is shown.

[0101] In step S301, a virtual machine is created for the device under test in the test device;

[0102] In step S302, instructions and / or data are transmitted between the testing device and the device under test through the virtual machine to test the device under test.

[0103] According to an embodiment of the present disclosure, a virtual machine can be created in a test device for a device under test, such as a vehicle-mounted smart box, and instructions and / or data can be transmitted between the test device and the device under test through the virtual machine, so that the device under test can be tested through the test device.

[0104] In the prior art, the vehicle-mounted smart box uses a fixed IP (Internet Protocol) address and IP network segment, so when multiple vehicle-mounted smart boxes are connected to a test device at the same time, although the test device will virtualize a network card device for each vehicle-mounted smart box, when the vehicle-mounted smart box assigns an IP address to the test device-side network card, since each vehicle-mounted smart box does not communicate with each other, it is impossible to know the actual IP allocation situation, so multiple vehicle-mounted smart boxes may assign the same IP address to the test device-side network card, resulting in a conflict when the test device is binding the IP and Mac address, resulting in only one network card device having an IP address, so that one test device cannot test multiple vehicle-mounted smart boxes at the same time. In the embodiment of the present disclosure, by creating a virtual machine for the device under test in the test device, an independent test environment can be established for each device under test, and multiple devices under test can be isolated at the data link layer, so that one test device can test multiple devices under test at the same time. According to the embodiment of the present disclosure, the test device can be connected to the device under test through a USB interface, and the test device can create a corresponding virtual machine for the device under test when it detects that the device under test is connected to the USB interface.

[0105] According to an embodiment of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine includes: transmitting instructions and / or data between the test device and the device under test through the virtual machine using the MirrorLink protocol. The MirrorLink protocol is a "Internet of Vehicles" standard jointly initiated and established by some internationally renowned mobile phone manufacturers and automobile manufacturers, which aims to standardize the effective connection between smart terminals and vehicle systems and form a good user experience. The use of the MirrorLink protocol realizes the interconnection between multiple smart terminals and multiple vehicle systems, and has good compatibility and scalability.

[0106] According to the embodiment of the present disclosure, the device under test may be a vehicle-mounted smart box supporting the MirrorLink protocol, or may be other terminal devices supporting the MirrorLink protocol, such as a smart phone, etc. According to the embodiment of the present disclosure, the test device and the device under test may also be connected using other communication protocols such as WLAN (wireless local area network) and Bluetooth.

[0107] According to an embodiment of the present disclosure, the step of creating a virtual machine for the device under test in the test device includes creating corresponding multiple virtual machines in the test device for multiple devices under test connected to the test device. For example, on the test device, 10 devices under test, such as vehicle-mounted smart boxes, can be connected via a USB port. Accordingly, the test device can establish 10 virtual machines, which are respectively connected to the 10 vehicle-mounted smart boxes via USB ports. The virtual machines are independent of each other, and the isolation of multiple devices under test at the data link layer is achieved, so that one test device can test multiple devices under test at the same time. For example, the USB interface of the test device monitors the USB device status. When it is detected that a device under test (for example, a vehicle-mounted smart box) is connected to the USB interface, a message of inserting the device under test is sent to the virtual machine management module, and the virtual machine management module creates a corresponding virtual machine for the device under test.

[0108] According to an embodiment of the present disclosure, the testing method further includes: generating a virtual network adapter for the device under test in the testing device; receiving a logical address assigned by the device under test to the virtual network adapter; and binding the physical address of the virtual network adapter to the logical address through the virtual machine.

[0109] In the disclosed embodiment, since a virtual machine is created for each device under test, the virtual machines can independently bind the logical address (e.g., IP address) and physical address (e.g., media access control MAC address) of the virtual network adapter, so even if several devices under test assign the same IP address to their corresponding virtual network adapters, it will not affect the connection and test process between the device under test and the test device. After the address is bound, the list of devices under test is updated.

[0110] According to an embodiment of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes: receiving incoming instructions and / or incoming data from the device under test through the virtual machine and performing operations corresponding to the incoming instructions and / or incoming data; and / or receiving user input through the virtual machine, obtaining outgoing instructions and / or outgoing data based on the user input, and sending outgoing instructions and / or outgoing data to the device under test.

[0111] For example, a two-way communication method can be used between the virtual machine and the device under test. The virtual machine can receive incoming data from the device under test, such as audio, video, image and other data that need to be played or displayed by the test device. The virtual machine can also receive incoming instructions from the device under test, such as instructions from the user to other devices connected to the test device through the control input of the device under test. In addition, the virtual machine can also send outgoing instructions to the device under test based on the input operation of the user (such as the tester), such as instructions for map navigation, selection of specific audio and video, or send outgoing data to the device under test, such as audio data of a song selected based on the user's voice.

[0112] According to an embodiment of the present disclosure, the incoming data includes display data of the device under test; and executing operations corresponding to the incoming instructions and / or incoming data through the virtual machine includes displaying an image corresponding to the display data through the virtual machine.

[0113] For example, the incoming data received by the virtual machine from the device under test may include display data of an image to be displayed on the display screen of the test device, and the image may be, for example, the desktop of the device under test, the application interface of the device under test being run, the video being played by the device under test, the map navigation screen of the device under test, etc. For example, the device under test such as a vehicle-mounted smart box may not have a display screen, but needs to be displayed on the display screen of the car's center console. During the test process, the image corresponding to the display data of the device under test is displayed on the screen of the test device through the virtual machine of the test device, which can simulate the scene of displaying the vehicle-mounted smart box on the car's center console screen in an actual working environment, thereby realizing the test of the corresponding functions of the device under test.

[0114] According to an embodiment of the present disclosure, displaying the image corresponding to the display data through the virtual machine includes: in a first display mode, simultaneously displaying thumbnail images corresponding to the display data of the multiple devices under test through multiple virtual machines; and in a second display mode, displaying a complete image corresponding to the display data of a specific device under test among the multiple devices under test.

[0115] According to an embodiment of the present disclosure, the test device can be connected to multiple devices under test at the same time to test the multiple devices under test. The first display mode of the test device can simultaneously display images of multiple devices under test, and the images can be, for example, the desktop of the device under test, the application interface of the device under test, the video being played by the device under test, the map navigation screen of the device under test, and the like. The image of the device under test is displayed in thumbnail form, and its number of pixels and resolution are lower than the full image of the second display mode. By simultaneously displaying the images of multiple devices under test in the first display mode, you can get an overview of the status of each device under test, quickly find out whether all the tested vehicle-mounted smart boxes are working properly, and you can easily switch to the image of any device under test.

[0116] According to an embodiment of the present disclosure, the second display mode of the test device can display a complete image of a specific device under test selected by the tester for interactive testing. According to an embodiment of the present disclosure, when the tester selects a thumbnail image of any device under test, the display mode switches from the first display mode to the second display mode. In the second display mode, a complete image of the specific device under test is displayed. The tester can perform input operations on the complete image. For example, the tester can operate in the navigation map area and the alternative song area of ​​the specific device under test displayed on the screen of the test device, such as selecting a destination navigation point or selecting a song to be played, thereby performing an interactive test on the selected specific device under test.

[0117] According to an embodiment of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes: creating a web page based on the display data through the virtual machine; and displaying the web page.

[0118] For example, the virtual machine can create a web page based on the display data and display the image of the device under test in the web page. To display the image through the web page, the virtual machine only needs to use a general browser such as IE to access the http service to display it, without developing dedicated image display software. During the system upgrade process, only the http service needs to be upgraded, which simplifies the system architecture and reduces the workload of development and maintenance.

[0119] According to an embodiment of the present disclosure, receiving user input through the virtual machine includes: receiving input made by the user on the web page through the virtual machine.

[0120] For example, in addition to displaying the image of the device under test through a web page, the virtual machine can also receive the tester's input in the web page, such as the touch input performed by the tester on the web page. The coordinates of the touch input can be uploaded to the virtual machine through the Websocket protocol. The virtual machine determines the corresponding control instructions based on the coordinates of the touch input, and obtains the corresponding outgoing data and / or outgoing instructions according to the control instructions. Displaying the image of the device under test and receiving the tester's touch input on the same web page well simulates the display image output and touch input on the car center console screen, which facilitates the test.

[0121] Figure 4 A block diagram of a device testing apparatus according to an embodiment of the present disclosure is shown.

[0122] like Figure 4 As shown, the device testing apparatus 400 includes:

[0123] A virtual machine creation module 401 is used to create a virtual machine for the device under test in the test device;

[0124] The instruction and data transmission module 402 is used to transmit instructions and / or data between the test device and the device under test through the virtual machine to test the device under test.

[0125] According to an embodiment of the present disclosure, creating a virtual machine for the device under test in the test device includes creating multiple virtual machines running in parallel in the test device for multiple devices under test connected to the test device.

[0126] Figure 5 A block diagram of a device testing apparatus according to an embodiment of the present disclosure is shown.

[0127] like Figure 5 As shown, the device testing apparatus 500 includes Figure 4 The same modules 401-402 also include additional modules:

[0128] A virtual network adapter generation module 403, used to generate a virtual network adapter for the device under test in the test device;

[0129] A logical address receiving module 404, configured to receive a logical address allocated by the device under test to the virtual network adapter;

[0130] The address binding module 405 is used to bind the physical address of the virtual network adapter to the logical address through the virtual machine.

[0131] According to an embodiment of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes:

[0132] Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or

[0133] The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

[0134] According to an embodiment of the present disclosure, the incoming data includes display data of the device under test;

[0135] The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

[0136] According to an embodiment of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes:

[0137] In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines;

[0138] In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

[0139] According to an embodiment of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes:

[0140] Creating a web page based on the display data by the virtual machine;

[0141] The web page is displayed.

[0142] According to an embodiment of the present disclosure, receiving user input through the virtual machine includes:

[0143] The user input on the web page is received through the virtual machine.

[0144] Figure 6 A structural block diagram of a computer system according to an embodiment of the present disclosure is shown.

[0145] like Figure 6As shown in , the computer system 600 may include one or more processors 601 and one or more memories 602. The one or more memories 602 are used to store one or more executable instructions. When the executable instructions are executed by the one or more processors 601, the following steps may be implemented:

[0146] A device testing method, characterized in that it includes: creating a virtual machine for a device to be tested in a testing device;

[0147] Instructions and / or data are transmitted between the testing device and the device under test through the virtual machine to test the device under test.

[0148] According to an embodiment of the present disclosure, creating a virtual machine for the device under test in the test device includes creating multiple virtual machines running in parallel in the test device for multiple devices under test connected to the test device.

[0149] According to an embodiment of the present disclosure, the device testing method further includes:

[0150] Generating a virtual network adapter for the device under test in the test device;

[0151] Receiving a logical address allocated by the device under test to the virtual network adapter;

[0152] The physical address of the virtual network adapter is bound to the logical address through the virtual machine.

[0153] According to an embodiment of the present disclosure, transmitting instructions and / or data between the test device and the device under test through the virtual machine to test the device under test includes:

[0154] Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or

[0155] The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

[0156] According to an embodiment of the present disclosure, the incoming data includes display data of the device under test;

[0157] The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

[0158] According to an embodiment of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes:

[0159] In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines;

[0160] In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

[0161] According to an embodiment of the present disclosure, displaying an image corresponding to the display data through the virtual machine includes:

[0162] Creating a web page based on the display data by the virtual machine;

[0163] The web page is displayed.

[0164] According to an embodiment of the present disclosure, receiving user input through the virtual machine includes:

[0165] The user input on the web page is received through the virtual machine.

[0166] According to an embodiment of the present disclosure, the device testing apparatus can be implemented in a distributed computer system. The distributed computer system can be implemented using multiple computers.

[0167] Figure 7 A structural block diagram showing a computer system architecture suitable for a device testing method according to an embodiment of the present disclosure.

[0168] like Figure 7 As shown, the computer system 700 includes a processor (CPU) 701, which can execute the above method according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 into a random access memory (RAM) 703. In the RAM 703, various programs and data required for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.

[0169] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN card, a modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage section 708 as needed.

[0170] In addition, according to an embodiment of the present disclosure, the method described above can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program tangibly contained on a readable medium thereof, and the computer program includes a program code for executing the above method. In such an embodiment, the computer program can be downloaded and installed from a network through the communication part 709, and / or installed from a removable medium 711.

[0171] According to the embodiments of the present disclosure, one computer system architecture as described above may be used to implement the method according to the embodiments of the present disclosure, or multiple computer system architectures as described above may be used to cooperate with each other to implement the method according to the embodiments of the present disclosure.

[0172] The flow charts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. 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 module, a program segment or a part of the 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 and / or flow chart, and the combination of the boxes in the block diagram and / 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.

[0173] The units or modules involved in the embodiments described in the present disclosure may be implemented by software or by programmable hardware. The units or modules described may also be arranged in a processor, and the names of these units or modules do not constitute limitations on the units or modules themselves in some cases.

[0174] As another aspect, the present disclosure further provides a computer-readable storage medium, which may be a computer-readable storage medium included in the device described in the above embodiment; or a computer-readable storage medium that exists independently and is not assembled into the device. The computer-readable storage medium stores one or more programs, and the programs are used by one or more processors to execute the method described in the present disclosure.

[0175] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the present disclosure is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the inventive concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other.

Claims

1. A device testing method, characterized in that: include: Create a virtual machine for the device under test in the test device; Generating a virtual network adapter for the device under test in the test device; Receiving a logical address assigned by the device under test to the virtual network adapter, wherein different devices under test assign the same or different logical addresses to their corresponding virtual network adapters; Binding the physical address of the virtual network adapter to the logical address through the virtual machine; Instructions and / or data are transmitted between the testing device and the device under test through the virtual machine to test the device under test.

2. The method according to claim 1, characterized in that: The creating a virtual machine for the device under test in the test device includes creating a plurality of virtual machines running in parallel in the test device for a plurality of devices under test connected to the test device.

3. The method according to claim 1, characterized in that The transmitting instructions and / or data between the test device and the device under test by using the virtual machine to test the device under test includes: Receiving, through the virtual machine, incoming instructions and / or incoming data from the device under test and executing operations corresponding to the incoming instructions and / or incoming data; and / or The user input is received through the virtual machine, an outgoing instruction and / or outgoing data is obtained based on the user input, and the outgoing instruction and / or outgoing data is sent to the device under test.

4. The method according to claim 3, characterized in that: The incoming data includes display data of the device under test; The performing, by the virtual machine, an operation corresponding to the incoming instruction and / or the incoming data includes displaying, by the virtual machine, an image corresponding to the display data.

5. The method according to claim 4, characterized in that The displaying, by the virtual machine, an image corresponding to the display data comprises: In the first display mode, thumbnail images corresponding to display data of the plurality of devices under test are displayed simultaneously through the plurality of virtual machines; In the second display mode, a complete image corresponding to the display data of a specific device under test among the plurality of devices under test is displayed.

6. The method according to claim 4, characterized in that The displaying, by the virtual machine, an image corresponding to the display data comprises: Creating a web page based on the display data by the virtual machine; The web page is displayed.

7. The method according to claim 3, characterized in that The receiving user input through the virtual machine includes: The virtual machine receives input from a user on a web page of the test device.

8. The method according to claim 1, characterized in that The creating a virtual machine for the device under test in the test device includes: when detecting that the device under test is connected to the test device through a universal serial bus interface, creating a virtual machine for the connected device under test in the test device.

9. The method according to claim 1, characterized in that: The step of creating a virtual machine for the device under test in the test device includes: creating a corresponding plurality of virtual machines for the plurality of devices under test, each virtual machine running a corresponding guest system in the test device.

10. A device testing apparatus, characterized in that: include: A virtual machine creation module, used to create a virtual machine for the device under test in the test device; A virtual network adapter generation module, used to generate a virtual network adapter for the device under test in the test device; A logical address receiving module, used for receiving the logical address assigned by the device under test to the virtual network adapter, wherein different devices under test assign the same or different logical addresses to their corresponding virtual network adapters; An address binding module, used to bind the physical address of the virtual network adapter to the logical address through the virtual machine; The instruction and data transmission module is used to transmit instructions and / or data between the test device and the device under test through the virtual machine to test the device under test.

11. A computer system comprising: processor; A memory storing executable instructions, which, when executed by a processor, implements the device testing method according to any one of claims 1 to 9.

12. A computer-readable storage medium storing executable instructions, which, when executed by a processor, implements the device testing method according to any one of claims 1 to 9.