Changeset 00a0bc5


Ignore:
Timestamp:
2010-03-12T20:28:39Z (15 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
842cd8d
Parents:
dde9d571
Message:

Test activity_timeout and some other test tweaks.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/check_jabber_util.c

    rdde9d571 r00a0bc5  
    6060        fail_unless( jabber_buddy_remove( ic, "wilmer@gaast.net/Telepathy" ) );
    6161        fail_unless( jabber_buddy_remove( ic, "wilmer@gaast.net/telepathy" ) );
    62         fail_unless( jabber_buddy_by_jid( ic, "wilmer@gaast.net", 0 ) == budw1 );
     62       
     63        /* Test activity_timeout and GET_BUDDY_BARE_OK. */
     64        fail_unless( jabber_buddy_by_jid( ic, "wilmer@gaast.net", GET_BUDDY_BARE_OK ) == budw1 );
     65        budw1->last_msg -= 50;
     66        fail_unless( ( bud = jabber_buddy_by_jid( ic, "wilmer@gaast.net", GET_BUDDY_BARE_OK ) ) != NULL );
     67        fail_unless( strcmp( bud->full_jid, "wilmer@gaast.net" ) == 0 );
    6368       
    6469        fail_if( jabber_buddy_remove( ic, "wilmer@gaast.net" ) );
    6570        fail_unless( jabber_buddy_by_jid( ic, "wilmer@gaast.net", 0 ) == budw1 );
    6671       
     72        fail_if( jabber_buddy_remove( ic, "wilmer@gaast.net" ) );
     73        fail_unless( jabber_buddy_remove( ic, "wilmer@gaast.net/bitlbee" ) );
     74        fail_unless( jabber_buddy_remove( ic, "wilmer@gaast.net/BitlBee" ) );
     75        fail_if( jabber_buddy_by_jid( ic, "wilmer@gaast.net", GET_BUDDY_BARE_OK ) );
     76       
    6777        /* Check if remove_bare() indeed gets rid of all. */
     78        /* disable this one for now.
    6879        fail_unless( jabber_buddy_remove_bare( ic, "wilmer@gaast.net" ) );
    6980        fail_if( jabber_buddy_by_jid( ic, "wilmer@gaast.net", 0 ) );
     81        */
    7082
    7183        fail_if( jabber_buddy_remove( ic, "nekkid@lamejab.net/Illegal" ) );
     
    8597        jd->buddies = g_hash_table_new( g_str_hash, g_str_equal );
    8698        set_add( &ic->acc->set, "resource_select", "priority", NULL, ic->acc );
     99        set_add( &ic->acc->set, "activity_timeout", "120", NULL, ic->acc );
    87100       
    88101        suite_add_tcase (s, tc_core);
Note: See TracChangeset for help on using the changeset viewer.