Small knowledge, big challenge! This paper is participating in theEssentials for programmers”Creative activities.

This paper has participated inProject DigginTo win the creative gift package and challenge the creative incentive money.

preface

We have a comprehensive understanding of the Android system in the preliminary analysis of the Android system, so we usually contact with the Android system is the user interaction layer – application layer.

In the application layer of the Android system, the form of the actual scene is different apps we usually use, such as life apps, social apps, photography apps and other apps that meet different needs.

For a Tester when we get the APP in hand, we will involuntarily open for experience, familiar with the APP UI layout, functional features and so on.

When we started using the APP, we were already testing it

So, what are the main testing methods for Android APP testing?

In this issue, we have summarized some common testing methods for Android apps. Let’s take a look

1. Technical architecture of APP

At present, the technical architecture of APP is mainly divided into Web APP, Native APP and Hybrid APP

  • Web APP: browser

    • Web App technology is mainly HTML, JavaScript, CSS and other technologies, as well as the mainstream HTML5
    • Major frameworks include CardKit, Kendo UI, and Framework7
  • Native APP: Android Native

    • Native App is written based on the mobile operating system and Java, providing better user experience and performance
    • The main frameworks have Dagger, RxKotlin
  • Hybrid APP: Hybrid technology

    • Hybrid APP Embedded Webview in native applications To access web pages through Webview has superior experience and cross-platform mainstream application development mode
    • The main framework is Cordova

2. APP test ideas

Suppose LD asked you to test the gold nuggets APP, what would we do?

The general steps are as follows:

  1. We need to go to the app store – search for nuggets – download and install it, and display it successfully on our phones
  2. Open the Nuggets APP and complete the registration and account login according to the page instructions
  3. In the gathering of many big man articles, randomly open, slide to view, comment, follow, exit and other operations
  4. Check your account and change your password in your personal Settings
  5. Nuggets APP has a new version, mobile update
  6. Use nuggets APP unable to extricate themselves, brush a day and a night
  7. The Nuggets APP sometimes displays overlapping fonts, affecting the reading experience

The above steps are summarized as follows:

3. APP basic function test

In the previous section, we used the Nuggets APP. When testing Tester, we will design use cases after we are familiar with the overall function of the APP

Functional testing testing methods are common:

  1. Equivalence class division: valid equivalence class and invalid equivalence class
  2. Boundary values: maximum and minimum values
  3. Error conjecture
  4. Cause-and-effect diagrams: Functional tests for interactional relationships
  5. Business flow chart: Test according to requirements design

4. APP performance test

What should we pay attention to when testing APP performance?

1. Pay attention to resource consumption (CPU, memory, traffic, and power consumption)

2. Startup time (cold startup, hot startup), (this is also used in many cloud measurement indicators)

3. Main page loading time

4. Memory leak, jitter, lag, page rendering (FPS)

5. APP security test

In the process of APP security testing, we need to pay attention to whether the APP excessively raises the rights, logCAT printing level, account security, etc

APP permissions

Ordinary users are extremely sensitive to their privacy issues. Therefore, we need to check the necessity of applying for certain permissions of APP. For unnecessary permissions, it is generally suggested to develop direct cancellation.

We can view the permission information of APK registration by using apPT tool

decompiling

In order to protect the company’s intellectual property and security concerns, some program developers will hard-code some sensitive information, such as passwords, into the source code. And if some poorly designed logic inside the program, there may be hidden vulnerabilities, once the source code leaks, huge security risks.

We can decompile APK using APKTool

The Log print

Google’s recommendations are based on the level at which developers know the appropriate use of logs, but it is likely that log. I (” XXX “, “sensitive information”), log.d (” XXX “, “sensitive information”), etc., will occur to different developers. Therefore, it is generally recommended not to output sensitive information logs in the production environment.

Account security

  1. Whether the password is stored in plain text in the background database You need to pay attention to the storage of the password during reviews and tests

  2. Whether password transmission is encrypted

  3. Account locking policy.

  4. Simultaneous conversations.

  5. Logout mechanism.

And so on, there are underlying interface security, database security is also what we should pay attention to

5. APP user experience test

There are a few things to focus on during user experience testing:

  • Whether the UI interface is beautiful
  • Smooth operation
  • Whether the function meets the user’s requirements

For example, blank space on the APP side greatly affects user experience

6. Other APP tests

  • Compatibility test

There are many Android phone manufacturers, and our APP needs to be compatible with different phone models, so compatibility testing is inevitable

  • Storage test

During storage test, the performance of the device is affected

7. The APP is abnormal

  • Device fragmentation

    Due to the diversity of devices, apps may behave differently on different devices

  • Memory management

    Low free memory, or unauthorized use of memory locations, can cause your App to fail

  • Changes in the Network

    Switching between different networks may affect the stability of the App

  • Bandwidth limitations

    The fast response time required for an APP may not be sufficient on a network with poor bandwidth

  • Code error

    New features that have not been tested can cause an App to fail in production

  • The user too much

    Too many connections can cause your App to crash

  • Third Party services

    Ads or pop-up screens can cause your App to crash

conclusion

This issue, summarizes the Android APP application testing ideas and methods.

In daily work, we have a better understanding of relevant functions of the APP and timely discover them before going online, so as to give users a better experience.

XDM, what methods do you usually use to test a new APP?

That’s the content of this episode. Please give us your thumbs up and comments. See you next time