Enlightenment CVS committal

Author  : ningerso
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src/bin/tests/button


Modified Files:
        ewl_button_test.c 


Log Message:
Extend button label unit test to cover setting a NULL label.

===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/bin/tests/button/ewl_button_test.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -3 -r1.4 -r1.5
--- ewl_button_test.c   15 Dec 2007 04:37:10 -0000      1.4
+++ ewl_button_test.c   15 Dec 2007 04:43:32 -0000      1.5
@@ -218,10 +218,15 @@
        button = ewl_button_new();
 
        ewl_button_label_set(EWL_BUTTON(button), "my_label");
-       if (strcmp("my_label", ewl_button_label_get(EWL_BUTTON(button))))
-               LOG_FAILURE(buf, len, "label_get dosen't match label_set");
+       if (!strcmp("my_label", ewl_button_label_get(EWL_BUTTON(button)))) {
+               ewl_button_label_set(EWL_BUTTON(button), NULL);
+               if (ewl_button_label_get(EWL_BUTTON(button)))
+                       LOG_FAILURE(buf, len, "label_get not NULL");
+               else
+                       ret = 1;
+       }
        else
-               ret = 1;
+               LOG_FAILURE(buf, len, "label_get doesn't match label_set");
 
        ewl_widget_destroy(button);
 



-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services
for just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to