Blender
V3.3
|
#include "testing/testing.h"
#include "MEM_guardedalloc.h"
#include "BLI_array_utils.h"
#include "BLI_listbase.h"
#include "BLI_path_util.h"
#include "BLI_ressource_strings.h"
#include "BLI_string.h"
Go to the source code of this file.
Macros | |
#define | TESTFAIL(test) |
Functions | |
static bool | listbase_is_valid (const ListBase *listbase) |
static int | char_switch (char *string, char ch_src, char ch_dst) |
TEST (listbase, FindLinkOrIndex) | |
TEST (listbase, FindLinkFromStringOrPointer) | |
TEST (listbase, FromLink) | |
static int | testsort_array_str_cmp (const void *a, const void *b) |
static int | testsort_listbase_str_cmp (const void *a, const void *b) |
static int | testsort_array_str_cmp_reverse (const void *a, const void *b) |
static int | testsort_listbase_str_cmp_reverse (const void *a, const void *b) |
static bool | testsort_listbase_array_str_cmp (ListBase *lb, char **arr, int arr_num) |
static bool | testsort_listbase_sort_is_stable (ListBase *lb, bool forward) |
TEST (listbase, Sort) | |
|
static |
Definition at line 55 of file BLI_listbase_test.cc.
Referenced by TEST().
Definition at line 14 of file BLI_listbase_test.cc.
References ListBase::first, ListBase::last, Link::next, blender::meshintersect::prev(), Link::prev, and TESTFAIL.
Referenced by TEST().
TEST | ( | listbase | , |
FindLinkFromStringOrPointer | |||
) |
Definition at line 107 of file BLI_listbase_test.cc.
References BLI_addtail(), BLI_findptr(), BLI_findstring(), BLI_freelistN(), BLI_listbase_clear(), BLI_listbase_string_or_index_find(), BLI_rfindptr(), BLI_rfindstring(), BLI_strncpy(), EXPECT_EQ(), MEM_callocN, next, blender::meshintersect::prev(), and ptr.
TEST | ( | listbase | , |
FindLinkOrIndex | |||
) |
Definition at line 68 of file BLI_listbase_test.cc.
References BLI_addtail(), BLI_findindex(), BLI_findlink(), BLI_findlinkfrom(), BLI_freelistN(), BLI_listbase_clear(), BLI_rfindlink(), EXPECT_EQ(), ListBase::first, and MEM_callocN.
TEST | ( | listbase | , |
FromLink | |||
) |
Definition at line 165 of file BLI_listbase_test.cc.
References BLI_addtail(), BLI_freelistN(), BLI_listbase_from_link(), EXPECT_EQ(), and MEM_callocN.
TEST | ( | listbase | , |
Sort | |||
) |
Definition at line 254 of file BLI_listbase_test.cc.
References BLI_addtail(), BLI_array_reverse, BLI_listbase_clear(), BLI_listbase_reverse(), BLI_listbase_sort(), BLI_strdupn(), char_switch(), LinkData::data, listbase_is_valid(), MEM_freeN, MEM_mallocN, testsort_array_str_cmp(), testsort_array_str_cmp_reverse(), testsort_listbase_array_str_cmp(), testsort_listbase_sort_is_stable(), testsort_listbase_str_cmp(), testsort_listbase_str_cmp_reverse(), and words10k.
Definition at line 193 of file BLI_listbase_test.cc.
References Freestyle::a, and usdtokens::b().
Referenced by TEST(), and testsort_array_str_cmp_reverse().
Definition at line 207 of file BLI_listbase_test.cc.
References Freestyle::a, usdtokens::b(), and testsort_array_str_cmp().
Referenced by TEST().
Definition at line 218 of file BLI_listbase_test.cc.
References LinkData::data, ListBase::first, and LinkData::next.
Referenced by TEST().
Definition at line 238 of file BLI_listbase_test.cc.
References LinkData::data, ListBase::first, LinkData::next, and next.
Referenced by TEST().
Definition at line 199 of file BLI_listbase_test.cc.
References Freestyle::a, usdtokens::b(), and LinkData::data.
Referenced by TEST(), and testsort_listbase_str_cmp_reverse().
Definition at line 212 of file BLI_listbase_test.cc.
References Freestyle::a, usdtokens::b(), and testsort_listbase_str_cmp().
Referenced by TEST().