Changeset 2fa5eed for variable.c


Ignore:
Timestamp:
Oct 24, 2006, 2:53:51 PM (18 years ago)
Author:
Alejandro R. Sedeño <asedeno@mit.edu>
Branches:
master, barnowl_perlaim, debian, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
Children:
bc220b2
Parents:
0138478
Message:
Fixed regression tests for booleans variables. They were testing a
'string' variable.

It looks like this broke when personalbell was tweaked to accept the
name of a filter to beep on [r358]. I've changed it to test
with rxping.

 --This line, and those below, will be ignored--

M    owl/variable.c
File:
1 edited

Legend:

Unmodified
Added
Removed
  • variable.c

    r0138478 r2fa5eed  
    923923  FAIL_UNLESS("setup", 0==owl_variable_dict_setup(&vd));
    924924
    925   FAIL_UNLESS("get bool", 0==owl_variable_get_bool(&vd,"personalbell"));
     925  FAIL_UNLESS("get bool", 0==owl_variable_get_bool(&vd,"rxping"));
    926926  FAIL_UNLESS("get bool (no such)", -1==owl_variable_get_bool(&vd,"mumble"));
    927   FAIL_UNLESS("get bool as string 1", 0==owl_variable_get_tostring(&vd,"personalbell", buf, 1024));
     927  FAIL_UNLESS("get bool as string 1", 0==owl_variable_get_tostring(&vd,"rxping", buf, 1024));
    928928  FAIL_UNLESS("get bool as string 2", 0==strcmp(buf,"off"));
    929   FAIL_UNLESS("set bool 1", 0==owl_variable_set_bool_on(&vd,"personalbell"));
    930   FAIL_UNLESS("get bool 2", 1==owl_variable_get_bool(&vd,"personalbell"));
    931   FAIL_UNLESS("set bool 3", 0==owl_variable_set_fromstring(&vd,"personalbell","off",0,0));
    932   FAIL_UNLESS("get bool 4", 0==owl_variable_get_bool(&vd,"personalbell"));
    933   FAIL_UNLESS("set bool 5", -1==owl_variable_set_fromstring(&vd,"personalbell","xxx",0,0));
    934   FAIL_UNLESS("get bool 6", 0==owl_variable_get_bool(&vd,"personalbell"));
     929  FAIL_UNLESS("set bool 1", 0==owl_variable_set_bool_on(&vd,"rxping"));
     930  FAIL_UNLESS("get bool 2", 1==owl_variable_get_bool(&vd,"rxping"));
     931  FAIL_UNLESS("set bool 3", 0==owl_variable_set_fromstring(&vd,"rxping","off",0,0));
     932  FAIL_UNLESS("get bool 4", 0==owl_variable_get_bool(&vd,"rxping"));
     933  FAIL_UNLESS("set bool 5", -1==owl_variable_set_fromstring(&vd,"rxping","xxx",0,0));
     934  FAIL_UNLESS("get bool 6", 0==owl_variable_get_bool(&vd,"rxping"));
    935935
    936936
Note: See TracChangeset for help on using the changeset viewer.