golang: Add support for @func(Class) and @func to be used over @property
Since the beginning of pygolang it is possible to define methods separate from class. For example @func(MyClass) def my_method(self, ...): ... will define MyClass.my_method(*). This works for regular functions and staticmethod/classmethod as well. But support for properties was missing because there was no use case so far. -> Add support for properties as well as I hit the need for it during my work on wendelin.core monitoring. Test class changed to inherit from object since on py2 properties work only for new-style classes. (*) see afa46cf5 (Turn pygopath into full pygolang) and 942ee900 (golang: Deprecate @method(cls) in favour of @func(cls)) for details. /reviewed-by @levin.zimmermann /reviewed-on !31
Status | Job ID | Name | Coverage | ||||||
---|---|---|---|---|---|---|---|---|---|
External | |||||||||
passed |
#738228
external
|
Pygolang.UnitTest-Master.Python2 |
00:01:22
|
||||||
passed |
#738357
external
|
Pygolang.UnitTest-Master.Python3 |
00:01:58
|
||||||
passed |
#737014
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:46:37
|
||||||
passed |
#736138
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:05:17
|
||||||
passed |
#737421
external
retried
|
Pygolang.UnitTest-Master.Python2 |
01:19:52
|
||||||
passed |
#735885
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:38
|
||||||
passed |
#737716
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:24
|
||||||
passed |
#735594
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:48:14
|
||||||
passed |
#735116
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:07:11
|
||||||
passed |
#736960
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:27
|
||||||
passed |
#737194
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:47
|
||||||
passed |
#734739
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:43
|
||||||
passed |
#736359
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:44
|
||||||
passed |
#737696
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:01:46
|
||||||
passed |
#734057
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:18
|
||||||
passed |
#737613
external
retried
|
Pygolang.UnitTest-Master.Python3 |
01:05:53
|
||||||
passed |
#737089
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:01:59
|
||||||
passed |
#737030
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:30:37
|
||||||
passed |
#736907
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:01:49
|
||||||
passed |
#736377
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:32
|
||||||
passed |
#736168
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:11:52
|
||||||
passed |
#735901
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:01:47
|
||||||
failed |
#735533
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:28
|
||||||
passed |
#735185
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:06:53
|
||||||
passed |
#734884
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:03:16
|
||||||