Software testing interview questions: How to test App performance?

APP performance testing is almost a must for client interviews.

Why Do App Performance Testing

If the APP always suffers from freezes or network delays, which reduces the user's favorability, the user may abandon the App and replace it with other applications of the same type. If the performance of the APP is good, the user experience is high, and the use is smooth and smooth, then the user stickiness of the application will inevitably increase.

So how do we do App performance testing, and what indicators should we focus on?

How to do App performance testing:

At present, existing tools are basically used for performance testing, such as the built-in tools in Android studio,

There are also some performance testing tools open sourced by other companies, which are mainly divided into two types, one is self-developed, and the other is open source/paid externally.

Self-developed: Generally, every company will have a self-developed platform for collecting performance data. Of course, some are purchased external services, which can be used after secondary development.

Open source: major companies have some open source software free for everyone to use, some are as follows

1、TraceView:

TraceView is a performance analysis tool for the Android platform, which is used to analyze computing performance and track lag problems caused by time-consuming methods. It presents the results in a graphical way, which intuitively reflects the execution time and number of executions of the code.

How to use: You can view it through the traceview that comes with Android studio (Android profiler). Developers use this tool more, and testers generally use other open source software.

2、Emmagee:

An Android performance monitoring tool developed by Netease, which can monitor the performance of a single application, and supports user-defined configuration monitoring sampling frequency and real-time performance display, and will eventually generate a performance statistics file.

Open source address: https://github.com/NetEase/Emmagee , where you can download the Emmagee installation package and related instructions. Only supports Android

3、GT:

GT (Portable tune) is open sourced by Tencent, it supports two mobile phone platforms, iOS and Android,

GT Android version is an Android APP portable testing platform independently developed by the Tencent MIG special testing group. It is an "Integrated Testing Environment" (ITE, Integrated Test Environment) that runs directly on the mobile phone.

Using GT, you can quickly perform performance tests (CPU, memory, traffic, power, frame rate/fluency, etc.), view development logs, view Crash logs, and network Capturing of data packets, debugging of APP internal parameters, time-consuming statistics of real machine codes, etc.

Open source address: https://github.com/Tencent/GT

4、soloPi:

Alipay's open source Android automation tool mainly has three main functions: recording playback, performance testing, and multi-controlling of one machine.

Recording and playback: SoloPi has the ability to record operations. Users only need to execute the use case steps through SoloPi, and SoloPi can record the user's operations and support playback on various devices. All of this can be done independently on the mobile phone.

Performance test: SoloPi can record various indicators of the application to be tested. You can observe the real-time updated data in the floating window, or record the performance data, and view the chart after the recording. At the same time, Soloπ also supports performance pressure, It can limit the CPU and memory, and reproduce the performance of applications in poor performance and poor network environments.

One device with multiple controls : SoloPi supports controlling multiple slave devices by operating one master device. It does not need to perform repeated and tedious compatibility tests on each device, which can greatly improve the efficiency of compatibility testing.

Open source address: https://github.com/alipay/SoloPi/wiki/Performance

These are the common performance testing tools on the market, and you can choose according to your needs. The author recently used SoloPi frequently.

Which indicators should APP performance testing focus on?

1. Time-consuming to start

The time spent on app startup is an important time for us, which is divided into hot start and cold start, etc.

The test startup time is more dependent on human judgment. Generally, we record the screen, and then use the frame segmentation tool to make a detailed time-consuming analysis of the screen rendering process at startup.

  • Advantages: It can give real feedback on the time-consuming of the App; no intrusion, offline analysis, and fine analysis of competing products
  • Disadvantages: Judgment time is more dependent on the judgment of human eyes, which cannot be judged by automated tools.

2. Power consumption per unit time, network traffic consumption per unit time

3. Utilization of resources related to mobile terminals: Not only the CPU, memory, disk I/O, and network on the server side are important content for performance testing, but also the CPU and memory on the mobile side are also one of the things we need to pay attention to.

  • cpu mainly focuses on the cpu occupancy rate at runtime and the cpu occupancy rate in the background
  • Memory Incremental memory entering a certain business scenario, and the total memory consumption of state-purchased execution in multi-link

4. Business response time and frame rate (fps): Due to the special structure of human beings, when the frame rate of the viewing screen is higher than 24, it will be considered coherent. The higher the fps, the smoother the picture.

  • FPS is divided into FPS when sliding. If it involves video/animation/live broadcast, the FPS when the business is running is also required.

Above, I made a brief introduction to APP performance testing, learned about common tools and performance indicators, and then learned how to design APP performance test cases, execute APP performance tests, write reports, etc.~

The following is the supporting information. For friends who do [software testing], it should be the most comprehensive and complete preparation warehouse. This warehouse also accompanied me through the most difficult journey. I hope it can help you too!

Software testing interview applet

The software test question bank maxed out by millions of people! ! ! Who is who knows! ! ! The most comprehensive quiz mini program on the whole network, you can use your mobile phone to do the quizzes, on the subway or on the bus, roll it up!

The following interview question sections are covered:

1. Basic theory of software testing, 2. web, app, interface function testing, 3. network, 4. database, 5. linux

6. web, app, interface automation, 7. performance testing, 8. programming basics, 9. hr interview questions, 10. open test questions, 11. security testing, 12. computer basics

Information acquisition method:

Guess you like

Origin blog.csdn.net/jiangjunsss/article/details/131766060