首页 > 其他分享 >[转载]pytest报AttributeError: module ‘pytest‘ has no attribute ‘main‘

[转载]pytest报AttributeError: module ‘pytest‘ has no attribute ‘main‘

时间:2022-11-07 10:58:24浏览次数:50  
标签:no attribute module pytest main AttributeError

转自:https://blog.csdn.net/yinying12/article/details/110522989

 

pytest报AttributeError: module ‘pytest‘ has no attribute ‘main‘

桑瑜

于 2020-12-03 11:01:52 发布

2510
收藏
分类专栏: pytest接口自动化 文章标签: python
版权

pytest接口自动化
专栏收录该内容
3 篇文章0 订阅
订阅专栏
pytest报AttributeError: module ‘pytest’ has no attribute ‘main’

 

 

百度了超级多,最后发现原来时文件夹的命名和pytest库的命名相同导致的
解决方法:新建一个文件夹,然后把之前的工程移到这个文件夹中,然后问题解决~
新手就容易犯命名不规范,然后导致各种奇葩的问题
————————————————
版权声明:本文为CSDN博主「桑瑜」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/yinying12/article/details/110522989

标签:no,attribute,module,pytest,main,AttributeError
From: https://www.cnblogs.com/workingdiary/p/16865211.html

相关文章

  • R语言使用逻辑回归Logistic、单因素方差分析anova、异常点分析和可视化分类iris鸢尾花
    摘要本文将探讨Fisher和Anderson ​​鸢尾花​​数据集中呈现的三个变量之间的关系,特别是virginica和versicolor级别的因变量变量物种对预测变量花瓣长度和花瓣宽度......
  • 自动化框架——pytest
     pytest的用处和学习目的:简单灵活,容易上手支持参数化能够支持简单的单元测试和复杂的功能测试,还可以用来做selenium/appnium等自动化测试、接口自动化测试(pytest+request......
  • NOSQL
    为什么用NoSQL?由于时代在进步,所以像以前的客户端对一个数据库已经过时了(数据越来越多),所以读取数据就越来越慢,后来就出现了,主从复制技术来达到读写分离(比如说读的2个读的,1......
  • 使用selenium-java报错:java.lang.NoSuchMethodError: com.google.common.base.Precond
    引入selenium-java依赖,发现到WebDriverdriver=newChromeDriver()时报错解决:<dependency><groupId>com.google.guava</groupId><a......
  • 洛谷 P3951 [NOIP2017 提高组] 小凯的疑惑 题解
    LuoguP3951[NOIP2017提高组]小凯的疑惑题解注:设\(A,B\)是两个集合,则\(A\timesB\)表示\(A\)与\(B\)的笛卡儿积(直积)。笛卡儿积的定义为\(S\timesM:=\{(s......
  • 20220604-note
    2022.6.4集训:欧拉回路postedon2022-06-1214:46:40|under学术|source2022.6.4集训:欧拉回路基本概念定义令$G=(V,E)$为一个图。对于$u\inV$,称$u$的入度......
  • 20220528-note
    2022.5.28集训:图论postedon2022-05-2812:02:29|under题解|source感谢vjudge.net提供技术支持。CF771ABearandFriendshipCondition题意给定$n$个点$......
  • "xxx cannot be cast to jakarta.servlet.Servlet "报错解决方式
    在做jsp的上机时候同学出现了一个500错误:com.kailong.servlet.ComputeBillcannotbecasttojaka.servlet.Servlet然后因为我用的tomcat是8.xx版本,并没有出现过这个情......
  • Batch Normalization: Accelerating Deep Network Training by Reducing Internal Cov
    BN层只是从一定程度上解决了梯度衰减的问题但是并没有完全解决如果输入值的差距过大会导致模型加BN层后loss依旧无变化。代码:fromenumimportautofromscipy.ioimpo......
  • Mysql InnoDB Redo log
    一丶什么是redoinnodb是以也为单位来管理存储空间的,增删改查的本质都是在访问页面,在innodb真正访问页面之前,需要将其加载到内存中的bufferpool中之后才可以访问,但是在聊......