From 35422a20b37f2f1a8cfad74246cfd28b2c27f478 Mon Sep 17 00:00:00 2001 From: "U. Artie Eoff" Date: Wed, 19 Sep 2012 16:29:11 -0700 Subject: [PATCH] bind_test: fixed BIG logic error (whoops). Signed-off-by: U. Artie Eoff --- src/core/test_bind_interface.cpp | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/src/core/test_bind_interface.cpp b/src/core/test_bind_interface.cpp index 8ac237a..8ae63ee 100644 --- a/src/core/test_bind_interface.cpp +++ b/src/core/test_bind_interface.cpp @@ -5,15 +5,31 @@ template ( - wl_display_bind( - *this, id, &interface - ) - ); - FAIL_IF(obj == NULL); + if (iface == str_interface) + { + object_ = static_cast( + wl_display_bind( + *this, id, &interface + ) + ); + } + } + + void teardown() + { + FAIL_IF(object_ == NULL); } +private: + O* object_; }; #define BIND_TEST(name) \ @@ -27,4 +43,4 @@ BIND_TEST(wl_shm) BIND_TEST(wl_output) BIND_TEST(wl_seat) BIND_TEST(wl_shell) -BIND_TEST(wl_data_device_manager) \ No newline at end of file +BIND_TEST(wl_data_device_manager) -- 2.7.4