[gnome-software/1290-dummy-plugin-s-key-colors-test-unreliable: 193/193] dummy: Correct the key-colors test
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/1290-dummy-plugin-s-key-colors-test-unreliable: 193/193] dummy: Correct the key-colors test
- Date: Thu, 29 Jul 2021 12:55:53 +0000 (UTC)
commit 400bbae9dc2c193d27273adfacec6d1a82e6851f
Author: Milan Crha <mcrha redhat com>
Date: Thu Jul 29 14:45:31 2021 +0200
dummy: Correct the key-colors test
There will never be more than 3 key colors returned, but there can
be returned less colors.
Closes https://gitlab.gnome.org/GNOME/gnome-software/-/issues/1290
plugins/dummy/gs-self-test.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/plugins/dummy/gs-self-test.c b/plugins/dummy/gs-self-test.c
index a2a2332a0..c94072aee 100644
--- a/plugins/dummy/gs-self-test.c
+++ b/plugins/dummy/gs-self-test.c
@@ -230,7 +230,8 @@ gs_plugins_dummy_key_colors_func (GsPluginLoader *plugin_loader)
g_assert_no_error (error);
g_assert (ret);
array = gs_app_get_key_colors (app);
- g_assert_cmpint (array->len, >=, 3);
+ g_assert_cmpint (array->len, <=, 3);
+ g_assert_cmpint (array->len, >, 0);
/* check values are in range */
for (i = 0; i < array->len; i++) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]