上一页 1 ··· 54 55 56 57 58 59 60 61 62 ··· 96 下一页
摘要: HTMLTestRunner.py """A TestRunner for use with the Python unit testing framework. Itgenerates a HTML report to show the result at a glance.The simples 阅读全文
posted @ 2020-01-18 23:16 干it的小张 阅读(221) 评论(0) 推荐(0) 编辑
摘要: """在执行用例的过程中,最终用例是否执行通过,是通过判断测试得到的实际结果与预期结果是否相等决定的。unittest框架的TestCase类提供下面这些方法用于测试结果的判断。""""""方法 检查 版本assertEqual(a,b) a==bassertNotEqual(a,b) a!=bas 阅读全文
posted @ 2020-01-18 23:09 干it的小张 阅读(182) 评论(0) 推荐(0) 编辑
摘要: calculator.py class Count: def __init__(self,a,b): self.a = int(a) self.b = int(b) #计算加法 def add(self): return self.a + self.b #计算减法 def sub(self): re 阅读全文
posted @ 2020-01-18 23:07 干it的小张 阅读(632) 评论(0) 推荐(0) 编辑
摘要: from selenium import webdriverimport os,timedriver = webdriver.Chrome()driver.get("http://www.baidu.com")#选择页面上所有的tag name为input的元素inputs = driver.fin 阅读全文
posted @ 2020-01-18 23:05 干it的小张 阅读(212) 评论(0) 推荐(0) 编辑
摘要: from selenium import webdriver#引入By类:from selenium.webdriver.common.by import Bydriver = webdriver.Chrome()#通过class属性定位输入框和百度一下、点表示通过class属性来定位元素:driv 阅读全文
posted @ 2020-01-18 23:04 干it的小张 阅读(220) 评论(0) 推荐(0) 编辑
上一页 1 ··· 54 55 56 57 58 59 60 61 62 ··· 96 下一页