Big refactoring, way simpler management of transformations. Early branch for upcoming version 0.2.
This commit is contained in:
14
tests/core/test_statistics.py
Normal file
14
tests/core/test_statistics.py
Normal file
@ -0,0 +1,14 @@
|
||||
from bonobo.core.statistics import WithStatistics
|
||||
|
||||
|
||||
class MyThingWithStats(WithStatistics):
|
||||
def get_statistics(self, *args, **kwargs):
|
||||
return (
|
||||
('foo', 42),
|
||||
('bar', 69),
|
||||
)
|
||||
|
||||
|
||||
def test_with_statistics():
|
||||
o = MyThingWithStats()
|
||||
assert o.get_statistics_as_string() == 'foo=42 bar=69'
|
||||
Reference in New Issue
Block a user