summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJens Georg <mail@jensge.org>2020-04-24 17:34:14 +0200
committerJens Georg <mail@jensge.org>2020-07-05 15:31:52 +0200
commit79f75e90e6f608539082f144c22b07160737ca75 (patch)
treed91e38115ebcac92b2e3c0146e4e9a8bf05a332b /tests
parent66e690169427f2f6ed22641b67b73ce658a9739d (diff)
downloadrygel-79f75e90e6f608539082f144c22b07160737ca75.tar.gz
tests: Catch exceptions
Diffstat (limited to 'tests')
-rw-r--r--tests/rygel-meta-config-test.vala14
1 files changed, 11 insertions, 3 deletions
diff --git a/tests/rygel-meta-config-test.vala b/tests/rygel-meta-config-test.vala
index 147748bc..0c2d94ec 100644
--- a/tests/rygel-meta-config-test.vala
+++ b/tests/rygel-meta-config-test.vala
@@ -49,13 +49,21 @@ test_meta_config_overrides () {
// Check that signalling a change for a value that only exists
// on lower priority will trigger a signal on the MetaConfig
- assert_true (instance.get_enabled (SECTION_A));
- assert_true (instance.get_enabled (SECTION_B));
+ try {
+ assert_true (instance.get_enabled (SECTION_A));
+ assert_true (instance.get_enabled (SECTION_B));
+ } catch (Error e) {
+ assert_not_reached ();
+ }
var id = instance.section_changed.connect ((section, entry) => {
assert_true (section == SECTION_B);
assert_true (entry == Rygel.SectionEntry.ENABLED);
- assert_false (instance.get_enabled (section));
+ try {
+ assert_false (instance.get_enabled (section));
+ } catch (Error e) {
+ assert_not_reached ();
+ }
});
second_config.toggl_enable (SECTION_B);