如何在不同的环境中处理不同的用户 [英] How to handle different users in different environments

查看:70
本文介绍了如何在不同的环境中处理不同的用户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

要使登录页面自动化,用户需要输入用户ID,安全性答案和密码.不同的环境有不同的用户.例如,qa和dev环境的用户具有不同的用户ID,安全性答案和密码.那么如何在自动化测试中正确处理用户信息呢?我们可以将所有属性存储在属性文件中,还有其他更好的解决方案吗?

解决方案

您可以尝试数据驱动框架自动化测试.将您的数据输入收集在 excel csv 之类的外部文件中,并使用在线提供的许多库读取数据,也许此链接将帮助您找到解决方案:

    • For a login page automation, a user need to enter user id, security answer and password. Different environment have different users. For example, users for qa and dev environments have different user id, security answer and password. So how to handle user information properly in the automation test? We can store all the properties in the properties file, any other better solutions?

      解决方案

      You can try Data Driven Framework automation test. Collect your data input in external file like excel csv, and read the data with the many libraries available online, maybe this link will help you find a solution :

      这篇关于如何在不同的环境中处理不同的用户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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