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

查看:23
本文介绍了如何在 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.

我有一个安卓应用和一个网络管理面板.该应用程序有一个同步按钮.当我按下按钮时,应用程序会与网络管理面板同步.现在,我想在 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 代理服务器.最快最简单的方法是使用 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

    参考文献:

    注意在某些 Android 操作系统版本上,您将无法使用外部应用程序配置 SSL 代理,例如 ProxyDroid

    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天全站免登陆