如何在JMeter中测试Android应用程序? [英] How to test Android app in JMeter?

查看:553
本文介绍了如何在JMeter中测试Android应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经知道将android设备配置为使用JMeter的代理,可以通过JMeter HTTP(S)测试脚本记录器记录移动应用程序网络活动.

I have come to know that Configuring android device to use JMeter's Proxy, it is possible to record mobile application network activity via JMeter HTTP(S) Test Script Recorder.

我有一个android应用程序和一个Web管理面板.该应用程序有一个同步按钮.当我按下按钮时,该应用程序将与网络管理面板同步.现在,我想在JMeter中测试同步过程.我想测试按下按钮后,同步请求已正确发送到服务器,并且服务器响应正确.是否可以在JMeter中进行测试?如果是,那该怎么办?

I have an android app and a Web Admin Panel. The app has a sync button. When I press the button, the app syncs with the web admin panel. Now, I want to test the sync process in JMeter. I want to test that after pressing the button, the request to sync is sent appropriately to the server and the server responses correctly. Is it possible to test this in JMeter? If yes, then how to do it?

推荐答案

您可以按照以下步骤使用JMeter记录移动应用程序的流量:

You can record mobile application traffic with JMeter by following next steps:

  1. 在JMeter中:

  1. In JMeter:

  • 设置JMeter代理服务器.最快,最简单的方法是使用

  • Set up JMeter proxy server. The fastest and the easiest way is to use JMeter Template feature. From JMeter main menu choose:

File -> Templates -> Recording -> Create

  • 展开工作台"

  • Expand "Workbench"

    在JMeter的"bin"文件夹中找到ApacheJMeterTemporaryRootCA.crt文件

    Locate ApacheJMeterTemporaryRootCA.crt file in JMeter's "bin" folder

    参考文献:

    • HTTP(S) Test Script Recorder
    • Apache JMeter Proxy Step by Step
    • Load Testing Mobile Apps. But Made Easy
    • How to change proxy settings in Android

    在某些Android操作系统版本上,您将无法使用外部应用程序(例如

    N.B. On some Android operating system versions you won't be able to configure SSL proxy using external application like ProxyDroid

    这篇关于如何在JMeter中测试Android应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

  • 查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆