Merge pull request #4041 from Zac-HD/user-properties-type
Ensure user_properties is a list
This commit is contained in:
commit
d2fc7ca6e0
5
AUTHORS
5
AUTHORS
|
@ -10,6 +10,7 @@ Ahn Ki-Wook
|
||||||
Alan Velasco
|
Alan Velasco
|
||||||
Alexander Johnson
|
Alexander Johnson
|
||||||
Alexei Kozlenok
|
Alexei Kozlenok
|
||||||
|
Allan Feldman
|
||||||
Anatoly Bubenkoff
|
Anatoly Bubenkoff
|
||||||
Anders Hovmöller
|
Anders Hovmöller
|
||||||
Andras Tim
|
Andras Tim
|
||||||
|
@ -179,6 +180,7 @@ Raphael Pierzina
|
||||||
Raquel Alegre
|
Raquel Alegre
|
||||||
Ravi Chandra
|
Ravi Chandra
|
||||||
Roberto Polli
|
Roberto Polli
|
||||||
|
Roland Puntaier
|
||||||
Romain Dorgueil
|
Romain Dorgueil
|
||||||
Roman Bolshakov
|
Roman Bolshakov
|
||||||
Ronny Pfannschmidt
|
Ronny Pfannschmidt
|
||||||
|
@ -223,6 +225,5 @@ Wim Glenn
|
||||||
Wouter van Ackooy
|
Wouter van Ackooy
|
||||||
Xuan Luong
|
Xuan Luong
|
||||||
Xuecong Liao
|
Xuecong Liao
|
||||||
|
Zac Hatfield-Dodds
|
||||||
Zoltán Máté
|
Zoltán Máté
|
||||||
Roland Puntaier
|
|
||||||
Allan Feldman
|
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
The ``.user_properties`` attribute of ``TestReport`` objects is a list
|
||||||
|
of (name, value) tuples, but could sometimes be instantiated as a tuple
|
||||||
|
of tuples. It is now always a list.
|
|
@ -110,7 +110,7 @@ class TestReport(BaseReport):
|
||||||
when,
|
when,
|
||||||
sections=(),
|
sections=(),
|
||||||
duration=0,
|
duration=0,
|
||||||
user_properties=(),
|
user_properties=None,
|
||||||
**extra
|
**extra
|
||||||
):
|
):
|
||||||
#: normalized collection node id
|
#: normalized collection node id
|
||||||
|
@ -136,7 +136,7 @@ class TestReport(BaseReport):
|
||||||
|
|
||||||
#: user properties is a list of tuples (name, value) that holds user
|
#: user properties is a list of tuples (name, value) that holds user
|
||||||
#: defined properties of the test
|
#: defined properties of the test
|
||||||
self.user_properties = user_properties
|
self.user_properties = list(user_properties or [])
|
||||||
|
|
||||||
#: list of pairs ``(str, str)`` of extra information which needs to
|
#: list of pairs ``(str, str)`` of extra information which needs to
|
||||||
#: marshallable. Used by pytest to add captured text
|
#: marshallable. Used by pytest to add captured text
|
||||||
|
|
Loading…
Reference in New Issue