_acs-tcl__util__randomize_list (private)
_acs-tcl__util__randomize_list
Defined in packages/acs-tcl/tcl/test/acs-tcl-test-procs.tcl
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: set _aa_export {} set body_count 1 foreach testcase_body {{ aa_equals "Empty list" [util::randomize_list {}] {} aa_equals "One-element list" [util::randomize_list {a}] {a} aa_true "Two-element list" [util_sets_equal_p [list a b] [util::randomize_list [list a b]]] set org_list [list a b c d e f g h i j] set randomized_list [util::randomize_list $org_list] aa_true "Ten-element list: $randomized_list" [util_sets_equal_p $org_list $randomized_list] set len [util::random_range 200] set org_list [list] for { set i 0 } { $i < $len } { incr i } { lappend org_list [ad_generate_random_string] } set randomized_list [util::randomize_list $org_list] aa_true "Long random list" [util_sets_equal_p $org_list $randomized_list] }} { aa_log "Running testcase body $body_count" set ::__aa_test_indent [info level] set catch_val [catch $testcase_body msg] if {$catch_val != 0 && $catch_val != 2} { aa_log_result "fail" "util__randomize_list (body $body_count): Error during execution: $msg, stack trace: \n$::errorInfo" } incr body_count }XQL Not present: Generic, PostgreSQL, Oracle