python之Ai测试Applitools使用
一:Appltools下载:
pip install eyes-selenium==3.16.2二:
注册:Appltools账号:
https://applitools.com/sign-up 三、获取:API:

新建: .py文件
from selenium import webdriver
from applitools.selenium import Eyes class HelloWorld: global driver
eyes = Eyes() # Initialize the eyes SDK and set your private API key.
eyes.api_key = 'lxxxxxxx' try: # Open a Chrome browser.
driver = webdriver.Chrome() # Start the test and set the browser's viewport size to 800x600.
eyes.open(driver, "Hello World!", "My first Selenium Python test!", {'width': 800, 'height': 600}) # Navigate the browser to the "hello world!" web-site.
driver.get('https://applitools.com/helloworld') # Visual checkpoint #1.
eyes.check_window('Hello!') # Click the 'Click me!' button.
driver.find_element_by_css_selector('button').click() # Visual checkpoint #2.
eyes.check_window('Click!') # End the test.
eyes.close() finally: # Close the browser.
driver.quit() # If the test was aborted before eyes.close was called, ends the test as aborted.
eyes.abort_if_not_closed()
运行即可:
查看分运行后分析结果:
https://applitools.com/users/login
下面奉上Applitools官方网站:
https://applitools.com/tutorials/
Applitools更多sdk:
https://applitools.com/tutorial
Applitools文档:
https://applitools.com/docs
Applitools演示:
https://applitools.com/request-demo?utm_source=tutorials
Applitools知识库:
https://help.applitools.com/hc/en-us/
python之Ai测试Applitools使用的更多相关文章
- 使用Python创建AI比你想象的轻松
使用 Python 创建 AI 比你想象的轻松 可能对AI领域,主要开发阶段,成就,结果和产品使用感兴趣.有数百个免费源和教程描述使用Python的AI.但是,没有必要浪费你的时间看他们.这里是一个详 ...
- selenium + python 多浏览器测试
selenium + python 多浏览器测试 支持库包 在学习 Python + Selenium 正篇之前,先来看下对多浏览器模拟的支持.目前selenium包中已包含webdriver,hel ...
- Python:渗透测试开源项目
Python:渗透测试开源项目[源码值得精读] sql注入工具:sqlmap DNS安全监测:DNSRecon 暴力破解测试工具:patator XSS漏洞利用工具:XSSer Web服务器压力测试工 ...
- python 实现九型人格测试小程序
用python实现九型人格测试,并把测试结果绘制成饼图,实现代码如下: # @Description: 九型人格 import xlrd, matplotlib.pyplot as plt data ...
- Appium使用Python运行appium测试的实例
Appium使用Python运行appium测试的实例 一. Appium之介绍 https://testerhome.com/topics/8038 详情参考--https://testerhom ...
- 基于Python的XSS测试工具XSStrike使用方法
基于Python的XSS测试工具XSStrike使用方法 简介 XSStrike 是一款用于探测并利用XSS漏洞的脚本 XSStrike目前所提供的产品特性: 对参数进行模糊测试之后构建合适的payl ...
- python 程序小测试
python 程序小测试 对之前写的程序做简单的小测试 ... # -*- encoding:utf-8 -*- ''' 对所写程序做简单的测试 @author: bpf ''' def GameOv ...
- 关于测试驱动的开发模式以及实战部分,建议看《Python Web开发测试驱动方法》这本书
关于测试驱动的开发模式以及实战部分,建议看<Python Web开发测试驱动方法>这本书
- Selenium 4 Python的最佳测试框架
随着Python语言的使用越来越流行,基于Python的测试自动化框架也越来越流行.在项目选择最佳框架时,开发人员和测试人员会有些无法下手.做出选择是应该判断很多事情,框架的脚本质量,测试用例的简单性 ...
随机推荐
- JavaScript兼容性问题 js兼容
1.获取事件对象: var e=e||event; 2.阻止冒泡: e:stopPropagation?e:stopPropagation():e.cancelBubble=true; 3.阻止浏览器 ...
- python变量d的说明
[变量] 什么是变量: 变:现实世界中的状态是会发生改变的. 量:记录现实世界中的状态,让计算机能够像人一样去识别世间万物 是变化的量 变量的组成: 变量名:变量名用来引用变量值,但凡需要用变量值,都 ...
- nginx.conf 配置解析之 http配置
官方文档 http://nginx.org/en/docs/参考链接: https://segmentfault.com/a/1190000012672431参考链接: https://segment ...
- navigator对象(了解即可)
navigator是window的子对象 navigator.appName // Web浏览器全称navigator.appVersion // Web浏览器厂商和版本的详细字符串navigator ...
- SpringCloud:gateway网关模块启动报错
1.错误信息 org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with na ...
- [已解决] Python logging 重复打印日志信息
问题描述 问题代码如下: def get_logger(logger_name): """得到日志对象""" logger = loggin ...
- Mongoose 内置 CURD 方 法、扩展 Mongoose Model 的静态方法和 实例方法
Mongoose 内置 CURD 方 法 Mongoose 内置 CURD 方 法文档地址:https://mongoosejs.com/docs/queries.html 常用的方法如下: Mode ...
- C复习---动态内存分配
原型extern void *malloc(unsigned int num_bytes);头文件#include <stdlib.h>#include <malloc.h>函 ...
- adb server version (31) doesn't match this client (41); killing...
1.有时候用adb工具去连接安卓设备,或者模拟器的时候,会提示adb server version(31) doesn’t match this client(41)这样的提示.如图 提示的字面意思就 ...
- java wait方法
wait方法是让当前线程等待,这里的当前线程不是指t,而是主线程. wait会释放锁,等到其他线程调用notify方法时再继续运行. 可以看下面的例子. 1 package com.citi.test ...