summaryrefslogtreecommitdiff
path: root/git/test/db/dulwich/lib.py
blob: 56734064968165631a7cf0cf2bc035d1a4c38723 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
"""dulwich specific utilities, as well as all the default ones"""

from git.test.lib import (
							InheritedTestMethodsOverrideWrapperMetaClsAutoMixin,
							needs_module_or_skip
						)

__all__ = ['needs_dulwich_or_skip', 'DulwichRequiredMetaMixin']

#{ Decoorators

def needs_dulwich_or_skip(func):
	"""Skip this test if we have no dulwich - print warning"""
	return needs_module_or_skip('dulwich')(func)

#}END decorators

#{ MetaClasses

class DulwichRequiredMetaMixin(InheritedTestMethodsOverrideWrapperMetaClsAutoMixin):
	decorator = [needs_dulwich_or_skip]

#} END metaclasses