随笔分类 - Python
主要是看虫师的。当然也看一些其他的python。
【playwright学习】wait_for_url的三种传参方法 in github create issue test
摘要:from playwright.sync_api import sync_playwright,Page,Playwright,Browser,expect import pytest import random import re @pytest.fixture(scope="module",au
阅读全文
【playwright学习】fixture和closure学习
摘要:学习的话主要材料是官网:https://playwright.dev/python/docs/auth 基础的话,像我一样薄弱就可以了。会一些java,但python会的不多,用得很少。上手贼容易,但是selenium也不怎么难 在学习之前,要弄清楚@pytest.fixture,closure(n
阅读全文
Selenium Edge Driver Python 自动化测试
摘要:Finally I got it. 没有自动化过edge,今天被小坑了一下,但是还好现在弄好了。 1. 查看edge 版本,我的是14.14393 2. https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/ 下载e
阅读全文
【Python学习】yield send我就说这么多
摘要:OUTPUT: yield1testm = Noneyield2test File "C:\pytest\Sele\Generator.py", line 36, in <module> result.send('test')TypeError: can't send non-None value
阅读全文
【Python学习】iterator 迭代器小练习
摘要:http://anandology.com/python-practice-book/iterators.html Problem 1: Write an iterator class reverse_iter, that takes a list and iterates it from the
阅读全文
Python 写了个小程序,耗时一天,结果才100多行
摘要:from selenium import webdriver import selenium.webdriver.support.ui as ui from selenium.webdriver.common.by import By from selenium.webdriver.support.ui import WebDriverWait from selenium.common.exce...
阅读全文
【Python学习】函数参数传递方法四种(位置,关键字,默认值,包裹位置,包裹关键字传递)
摘要:1. 位置传递: 2. 关键字传递 3. 默认值参数 调用: 4. 包裹传递 调用: 输出: 5. 解包
阅读全文