From f4298f94292b99e7f384f8048e695b8263d495f2 Mon Sep 17 00:00:00 2001 From: Andrew Clayton Date: Tue, 23 Jul 2024 18:55:18 +0100 Subject: tests: Fix `/status' endpoint to cater for lists We can now get list objects from the /status endpoint in the case of having different versions of the same language module. That led to this error > return d1 - d2 E TypeError: unsupported operand type(s) for -: 'list' and 'list' We already cover a similar case for when we have simple strings so add this to that. Signed-off-by: Andrew Clayton --- test/unit/status.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test') diff --git a/test/unit/status.py b/test/unit/status.py index d8bb4e41..679008d0 100644 --- a/test/unit/status.py +++ b/test/unit/status.py @@ -31,7 +31,7 @@ class Status: if k in d2 } - if isinstance(d1, str): + if isinstance(d1, str) or isinstance(d1, list): return d1 == d2 return d1 - d2 -- cgit