当前位置:网站首页>PO模式简介「建议收藏」
PO模式简介「建议收藏」
2022-06-30 17:45:00 【全栈程序员站长】
大家好,又见面了,我是你们的朋友全栈君。
PO模式简介
1.什么是PO模式
PO模型是:Page Object Model的简写 页面对象模型
作用:就是把测试页面和测试脚本进行分离,即把页面封装成类,供测试脚本进行调用;
分层机制,让不同层去做不同类型的事情,让代码结构清晰,增加复用性。
PO设计模式是Selenium自动化测试中最佳的设计模式之一,主要体现在对界面交互细节的封装2. 不使用PO设计会出现以下几种情况:
- 复用性不太好,扩展性不好,易读性差,不好维护,UI界面频繁的项目维护起来比较麻烦。
3.PO模式的优缺点
优点:
提高代码的可读性
减少了代码的重复
提高代码的可维护性,特别是针对UI界面频繁的项目
缺点:
造成项目结构比较复杂,因为是根据流程进行了模块化处理发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/132245.html原文链接:https://javaforall.cn
边栏推荐
- 深度学习编译器的理解
- iCloud照片无法上传或同步怎么办?
- Hospital online consultation applet source code Internet hospital source code smart hospital source code
- 一点比较有意思的模块
- OneFlow源码解析:算子签名的自动推断
- Distributed transaction
- Vulnerability recurrence ----- 38. Thinkphp5 5.0.23 Remote Code Execution Vulnerability
- Pytorch learning (III)
- Summary of methods for offline installation of chrome extensions in China
- slice
猜你喜欢

Classic problem of leetcode dynamic programming (I)

详解单例模式

拓維信息使用 Rainbond 的雲原生落地實踐

When selecting smart speakers, do you prefer "smart" or "sound quality"? This article gives you the answer

云上“视界” 创新无限 | 2022阿里云直播峰会正式上线

Digital intelligent supplier management system solution for coal industry: data driven, supplier intelligent platform helps enterprises reduce costs and increase efficiency

Entry node of link in linked list - linked list topic

EasyNVR平台设备通道均在线,操作出现“网络请求失败”是什么原因?

挑选智能音箱时,首选“智能”还是“音质”?这篇文章给你答案

Deep learning compiler understanding
随机推荐
mysql for update 死锁问题排查
《Go题库·15》go struct 能不能比较?
TiDB Dashboard里面可以写sql执行吗
torch stack() meshgrid()
How to do a good job in software system demand research? Seven weapons make it easy for you to do it
云上“视界” 创新无限 | 2022阿里云直播峰会正式上线
Where do the guests come from
Compare the audio librosa library with the Mel spectrogram in the torchaudio library
冰河老师的书
使用excel快速生成sql语句
MySQL找不到mysql.sock文件的临时解
充值满赠,IM+RTC+X 全通信服务「回馈季」开启
What if the apple watch fails to power on? Apple watch can not boot solution!
Merged binary tree of leetcode
教你30分钟快速搭建直播间
iCloud照片无法上传或同步怎么办?
传统微服务框架如何无缝过渡到服务网格 ASM
PyTorch学习(三)
Electronic components bidding and purchasing Mall: optimize traditional purchasing business and speed up enterprise digital upgrading
At present, the big guys are joining the two streams of flinksql, cdcmysql and Kafka, and the results are put into MySQL or KA