测试时禁用网络连接
项目描述
Python包,用于测试目的模拟互联网故障。
此分支修复了原始存储库中的错误。库正常工作,100%。
安装
$ pip install internet-sabotage3
用法
from internet_sabotage import no_connection
with no_connection():
response = requests.get('http://httpbin.org/ip')
或
from internet_sabotage import no_connection
@no_connection
def test_something():
pass
许可证
MIT
项目详情
关闭
internet-sabotage3-0.1.6.tar.gz 的哈希
算法 | 哈希摘要 | |
---|---|---|
SHA256 | c42a6ac3edf145500ceb0b57045385999958fe6565011ecad5bb96ad8848dccf |
|
MD5 | 6503501468338dd33b88342c2a2092a8 |
|
BLAKE2b-256 | ce649d63822630400216be5cf621f6292fea5980f065f1bd2b7eb24eaac0de4f |