Skip to content
Snippets Groups Projects

Merge of check_tests_and_examples to dev

Merged Vincent Texier requested to merge check_tests_and_examples into dev
3 unresolved threads
44 files
+ 1243
717
Compare changes
  • Side-by-side
  • Inline
Files
44
@@ -4,7 +4,7 @@ Created on 2 déc. 2014
@@ -4,7 +4,7 @@ Created on 2 déc. 2014
@author: inso
@author: inso
"""
"""
import re
import re
from typing import TypeVar, Type
from typing import TypeVar, Type, Optional
from .block_uid import BlockUID
from .block_uid import BlockUID
from .document import Document, MalformedDocumentError
from .document import Document, MalformedDocumentError
@@ -72,7 +72,7 @@ class Membership(Document):
@@ -72,7 +72,7 @@ class Membership(Document):
membership_type: str,
membership_type: str,
uid: str,
uid: str,
identity_ts: BlockUID,
identity_ts: BlockUID,
signature: str,
signature: Optional[str] = None,
) -> None:
) -> None:
"""
"""
Create a membership document
Create a membership document
@@ -86,7 +86,12 @@ class Membership(Document):
@@ -86,7 +86,12 @@ class Membership(Document):
:param identity_ts: BlockUID of the identity
:param identity_ts: BlockUID of the identity
:param signature: Signature of the document
:param signature: Signature of the document
"""
"""
super().__init__(version, currency, [signature])
if signature:
 
signatures = [signature]
 
else:
 
signatures = []
 
super().__init__(version, currency, signatures)
 
self.issuer = issuer
self.issuer = issuer
self.membership_ts = membership_ts
self.membership_ts = membership_ts
self.membership_type = membership_type
self.membership_type = membership_type
Loading