mirror of
https://github.com/bringout/oca-ocb-core.git
synced 2026-04-20 07:32:08 +02:00
17.0 vanilla
This commit is contained in:
parent
2e65bf056a
commit
df627a6bba
328 changed files with 578149 additions and 759311 deletions
|
|
@ -7,3 +7,4 @@ See https://github.com/python/cpython/tree/3.10/Lib/unittest for reference files
|
|||
|
||||
from . import common
|
||||
from .common import *
|
||||
from .form import Form, O2MProxy, M2MProxy
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
|
||||
import contextlib
|
||||
from typing import Optional
|
||||
|
||||
import astroid
|
||||
|
|
@ -12,9 +10,7 @@ except ImportError:
|
|||
|
||||
|
||||
class OdooBaseChecker(checkers.BaseChecker):
|
||||
with contextlib.suppress(AttributeError): # TODO, remove once pylint minimal version is 3.0.0
|
||||
__implements__ = interfaces.IAstroidChecker
|
||||
# see https://github.com/pylint-dev/pylint/commit/358264aaf622505f6d2e8bc699618382981a078c
|
||||
__implements__ = interfaces.IAstroidChecker
|
||||
name = 'odoo'
|
||||
|
||||
msgs = {
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -192,8 +192,7 @@ class OdooTestResult(object):
|
|||
return length
|
||||
|
||||
def __repr__(self):
|
||||
return ("<%s.%s run=%i errors=%i failures=%i>" %
|
||||
(self.__class__.__module__, self.__class__.__qualname__, self.testsRun, len(self.errors_count), len(self.failures_count)))
|
||||
return f"<{self.__class__.__module__}.{self.__class__.__qualname__} run={self.testsRun} errors={self.errors_count} failures={self.failures_count}>"
|
||||
|
||||
def __str__(self):
|
||||
return f'{self.failures_count} failed, {self.errors_count} error(s) of {self.testsRun} tests'
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ class TestSuite(BaseTestSuite):
|
|||
return
|
||||
if result._moduleSetUpFailed:
|
||||
return
|
||||
if getattr(currentClass, "__unittest_skip__", False):
|
||||
if currentClass.__unittest_skip__:
|
||||
return
|
||||
|
||||
currentClass._classSetupFailed = False
|
||||
|
|
@ -99,7 +99,7 @@ class TestSuite(BaseTestSuite):
|
|||
return
|
||||
if previousClass._classSetupFailed:
|
||||
return
|
||||
if getattr(previousClass, "__unittest_skip__", False):
|
||||
if previousClass.__unittest_skip__:
|
||||
return
|
||||
try:
|
||||
previousClass.tearDownClass()
|
||||
|
|
|
|||
|
|
@ -70,10 +70,10 @@ class TagsSelector(object):
|
|||
_logger.debug("Skipping test '%s' because no test_tag found.", test)
|
||||
return False
|
||||
|
||||
test_module = getattr(test, 'test_module', None)
|
||||
test_class = getattr(test, 'test_class', None)
|
||||
test_module = test.test_module
|
||||
test_class = test.test_class
|
||||
test_tags = test.test_tags | {test_module} # module as test_tags deprecated, keep for retrocompatibility,
|
||||
test_method = getattr(test, '_testMethodName', None)
|
||||
test_method = test._testMethodName
|
||||
|
||||
test._test_params = []
|
||||
|
||||
|
|
|
|||
|
|
@ -17,8 +17,8 @@ import odoo.tests.loader
|
|||
_logger = logging.getLogger('odoo.tests.test_module_operations')
|
||||
|
||||
BLACKLIST = {
|
||||
'auth_ldap', 'document_ftp', 'website_instantclick', 'pad',
|
||||
'pad_project', 'note_pad', 'pos_cache', 'pos_blackbox_be',
|
||||
'auth_ldap',
|
||||
'pos_blackbox_be',
|
||||
}
|
||||
IGNORE = ('hw_', 'theme_', 'l10n_', 'test_')
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue