会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
xmb
博客园
首页
新随笔
联系
订阅
管理
2020年2月20日
TPS与响应时间之间的关系
该文被密码保护。
阅读全文
posted @ 2020-02-20 15:47 xmb
阅读(0)
评论(0)
推荐(0)
2020年2月19日
性能测试的概念
该文被密码保护。
阅读全文
posted @ 2020-02-19 16:36 xmb
阅读(1)
评论(0)
推荐(0)
2019年12月1日
python_unittest参数化
摘要: unittest参数化 1 import parameterized 2 import unittest,BeautifulReport 3 4 #数据驱动 5 #代码驱动 6 #关键字驱动 7 8 data = [ 9 ['admin','123456',True,'正常登录'], 10 ['ad
阅读全文
posted @ 2019-12-01 00:07 xmb
阅读(244)
评论(0)
推荐(0)
python_单元测试unittest
摘要: 单元测试unittest 1、单元测试用例 1 import unittest 2 def add(a,b): 3 return a + b 4 result = add(1,1) 5 6 class AddTest(unittest.TestCase): #继承unittest.TestCase
阅读全文
posted @ 2019-12-01 00:04 xmb
阅读(286)
评论(0)
推荐(0)
2019年11月30日
python_多进程
摘要: 一、多进程 1、多线程,多进程 多线程: 适用于io密集型任务 多进程 适用于cpu密集型任务 1 import multiprocessing,time,virtualenv 2 def down_load(): 3 time.sleep(5) 4 print('运行完了') 5 6 if __n
阅读全文
posted @ 2019-11-30 22:21 xmb
阅读(119)
评论(0)
推荐(0)
python_锁
摘要: 一、锁 1、多个线程操作同一个数据的时候,就的加锁 实例: import threading num = 0 lock = threading.Lock() #申请一把锁 def add(): global num #lock.acquire() #加锁 #num+=1 #lock.release(
阅读全文
posted @ 2019-11-30 22:08 xmb
阅读(150)
评论(0)
推荐(0)
python_守护线程
摘要: 一、守护线程 1、主线程结束,子线程立马结束 实例: 1 import threading,time 2 def down_load(): 3 time.sleep(5) 4 print('运行完了') 5 for i in range(10): 6 t = threading.Thread(tar
阅读全文
posted @ 2019-11-30 21:59 xmb
阅读(129)
评论(0)
推荐(0)
python_线程池
摘要: 一、线程池 实例: 1 import threadpool 2 import requests,time,threading 3 from hashlib import md5 4 def down_load_pic(url): 5 req = requests.get(url) 6 m = md5
阅读全文
posted @ 2019-11-30 21:55 xmb
阅读(151)
评论(0)
推荐(0)
python_异步任务
摘要: 一、异步任务 实例: 1 import yagmail,threading 2 def send_mail(): 3 smtp = yagmail.SMTP(host='smtp.163.com',user='xmb@163.com', 4 password='fsdfsf') 5 smtp.sen
阅读全文
posted @ 2019-11-30 21:48 xmb
阅读(900)
评论(0)
推荐(0)
python_多线程下载文件
摘要: 一、多线程下载文件 1 import requests,time,threading 2 from hashlib import md5 3 result = {} 4 def down_load_pic(url): 5 req = requests.get(url) 6 m = md5(url.e
阅读全文
posted @ 2019-11-30 21:40 xmb
阅读(1309)
评论(0)
推荐(0)
下一页
公告