diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2012-10-26 09:08:59 +0200 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2012-10-26 09:08:59 +0200 |
commit | 92b48e8afa58cab0612fdc49546ea66666e73ab5 (patch) | |
tree | 28f273ba6f36546fa6635765af2f7e0aec23329c | |
parent | 8659889054f49ff674562c0f7c8ae7929e837d67 (diff) | |
download | ayatana-indicator-power-92b48e8afa58cab0612fdc49546ea66666e73ab5.tar.gz ayatana-indicator-power-92b48e8afa58cab0612fdc49546ea66666e73ab5.tar.bz2 ayatana-indicator-power-92b48e8afa58cab0612fdc49546ea66666e73ab5.zip |
add unit tests to confirm the device refcounts are correct s.t. IndicatorPower isn't leaking devices
-rw-r--r-- | tests/test-indicator.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/test-indicator.cc b/tests/test-indicator.cc index b9f7321..5480774 100644 --- a/tests/test-indicator.cc +++ b/tests/test-indicator.cc @@ -71,6 +71,8 @@ class IndicatorTest : public ::testing::Test virtual void TearDown() { + ASSERT_EQ (1, G_OBJECT(battery_device)->ref_count); + ASSERT_EQ (1, G_OBJECT(ac_device)->ref_count); g_object_unref (battery_device); g_object_unref (ac_device); } |