Back to index

indicator-power  12.10.0
Protected Member Functions | Static Protected Member Functions
DeviceTest Class Reference

List of all members.

Protected Member Functions

virtual void TearDown ()
void check_icon_names (const IndicatorPowerDevice *device, const char *expected)
void check_strings (const IndicatorPowerDevice *device, const char *expected_timestring, const char *expected_details, const char *expected_accessible)

Static Protected Member Functions

virtual void SetUp ()

Detailed Description

Definition at line 37 of file test-device.cc.


Member Function Documentation

void DeviceTest::check_icon_names ( const IndicatorPowerDevice *  device,
const char *  expected 
) [inline, protected]

Definition at line 52 of file test-device.cc.

    {
      char ** names = indicator_power_device_get_icon_names (device);
      char * str = g_strjoinv (";", names);
      ASSERT_STREQ (expected, str);
      g_free (str);
      g_strfreev (names);
    }

Here is the call graph for this function:

void DeviceTest::check_strings ( const IndicatorPowerDevice *  device,
const char *  expected_timestring,
const char *  expected_details,
const char *  expected_accessible 
) [inline, protected]

Definition at line 61 of file test-device.cc.

    {
      char * timestring = NULL;
      char * details = NULL;
      char * accessible = NULL;

      indicator_power_device_get_time_details (device, &timestring, &details, &accessible);
      EXPECT_STREQ (expected_timestring, timestring);
      EXPECT_STREQ (expected_details, details);
      EXPECT_STREQ (expected_accessible, accessible);

      g_free (accessible);
      g_free (details);
      g_free (timestring);
    }

Here is the call graph for this function:

virtual void DeviceTest::SetUp ( ) [inline, static, protected, virtual]

Definition at line 41 of file test-device.cc.

    {
      ensure_glib_initialized ();
    }
virtual void DeviceTest::TearDown ( ) [inline, protected, virtual]

Definition at line 46 of file test-device.cc.

    {
    }

The documentation for this class was generated from the following file: