Index: openacs-4/packages/acs-admin/tcl/test/acs-admin-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/tcl/test/acs-admin-procs.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/acs-admin/tcl/test/acs-admin-procs.tcl 7 Aug 2017 23:47:45 -0000 1.5 +++ openacs-4/packages/acs-admin/tcl/test/acs-admin-procs.tcl 19 Jul 2018 12:15:19 -0000 1.6 @@ -6,9 +6,13 @@ @cvs-id $Id$ } -aa_register_case -cats {api smoke} apm_higher_version_installed_p { +aa_register_case -cats { + api smoke +} -procs { + apm_higher_version_installed_p +} apm_higher_version_installed_p { Test apm_higher_version_installed_p proc. -} { +} { aa_run_with_teardown \ -rollback \ Index: openacs-4/packages/acs-authentication/tcl/test/acs-authentication-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-authentication/tcl/test/acs-authentication-procs.tcl,v diff -u -r1.49 -r1.50 --- openacs-4/packages/acs-authentication/tcl/test/acs-authentication-procs.tcl 19 Jul 2018 11:49:46 -0000 1.49 +++ openacs-4/packages/acs-authentication/tcl/test/acs-authentication-procs.tcl 19 Jul 2018 12:15:19 -0000 1.50 @@ -63,7 +63,7 @@ -password "blabla"] aa_equals "auth_status for bad password authentication" $auth_info(auth_status) "bad_password" - aa_true "auth_message for bad password authentication" [expr {$auth_info(auth_message) ne ""}] + aa_true "auth_message for bad password authentication" {$auth_info(auth_message) ne ""} # Blank password array unset auth_info @@ -74,7 +74,7 @@ -password ""] aa_equals "auth_status for blank password authentication" $auth_info(auth_status) "bad_password" - aa_true "auth_message for blank password authentication" [expr {$auth_info(auth_message) ne ""}] + aa_true "auth_message for blank password authentication" {$auth_info(auth_message) ne ""} # Incorrect username array unset auth_info @@ -85,7 +85,7 @@ -password $password] aa_equals "auth_status for bad username authentication" $auth_info(auth_status) "no_account" - aa_true "auth_message for bad username authentication" [expr {$auth_info(auth_message) ne ""}] + aa_true "auth_message for bad username authentication" {$auth_info(auth_message) ne ""} # Blank username array unset auth_info @@ -96,7 +96,7 @@ -password $password] aa_equals "auth_status for blank username authentication" $auth_info(auth_status) "auth_error" - aa_true "auth_message for blank username authentication" [expr {$auth_info(auth_message) ne ""}] + aa_true "auth_message for blank username authentication" {$auth_info(auth_message) ne ""} # Authority bogus array unset auth_info @@ -108,7 +108,7 @@ -password $password] aa_equals "auth_status for bad authority_id authentication" $auth_info(auth_status) "failed_to_connect" - aa_true "auth_message for bad authority_id authentication" [expr {$auth_info(auth_message) ne ""}] + aa_true "auth_message for bad authority_id authentication" {$auth_info(auth_message) ne ""} # Closed account status set closed_states {banned rejected "needs approval" deleted} @@ -180,7 +180,7 @@ } aa_false "No creation_message for successful creation" \ - [expr {[info exists user_info(creation_message)] && $user_info(creation_message) ne ""}] + {[info exists user_info(creation_message)] && $user_info(creation_message) ne ""} aa_true "returns user_id" [info exists user_info(user_id)] if { [info exists user_info(user_id)] } { @@ -205,9 +205,9 @@ array unset elm_msgs array set elm_msgs $user_info(element_messages) aa_true "element_message for username exists" \ - [expr {[info exists elm_msgs(username)] && $elm_msgs(username) ne ""}] + {[info exists elm_msgs(username)] && $elm_msgs(username) ne ""} aa_true "element_message for email exists" \ - [expr {[info exists elm_msgs(email)] && $elm_msgs(email) ne ""}] + {[info exists elm_msgs(email)] && $elm_msgs(email) ne ""} } set user_id [acs_user::get_by_username -username auth_create_user1] if { $user_id ne "" } { @@ -233,7 +233,7 @@ array set elm_msgs $user_info(element_messages) if { [aa_true "element_message(email) exists" \ - [expr {[info exists elm_msgs(email)] && $elm_msgs(email) ne ""}] ]} { + {[info exists elm_msgs(email)] && $elm_msgs(email) ne ""} ]} { aa_log "element_message(email) = $elm_msgs(email)" } if { [aa_true "element_message(first_names) exists" [info exists elm_msgs(first_names)] ]} { @@ -319,8 +319,8 @@ aa_log "Elements array: '[array get element_array]'" - aa_true "there is more than one required element" [expr {[llength $element_array(required)] > 0}] - aa_true "there is more than one optional element" [expr {[llength $element_array(optional)] > 0}] + aa_true "there is more than one required element" {[llength $element_array(required)] > 0} + aa_true "there is more than one optional element" {[llength $element_array(optional)] > 0} } aa_register_case \ @@ -334,7 +334,7 @@ } { set form_elements [auth::get_registration_form_elements] - aa_true "Form elements are not empty: $form_elements" [expr {$form_elements ne ""}] + aa_true "Form elements are not empty: $form_elements" {$form_elements ne ""} } ########### @@ -475,7 +475,7 @@ -username $test_vars(username)] aa_equals "status ok" $password_result(password_status) "ok" - aa_true "non-empty message" [expr {$password_result(password_message) ne ""}] + aa_true "non-empty message" {$password_result(password_message) ne ""} } } @@ -520,7 +520,7 @@ -username $test_vars(username)] aa_equals "retrieve pwd from local auth" $result(password_status) "ok" - aa_true "must have message on failure" [expr {$result(password_message) ne ""}] + aa_true "must have message on failure" {$result(password_message) ne ""} } aa_register_case \ @@ -700,7 +700,7 @@ set parameters [array names parameters_array] - aa_true "List of parameters is not empty" [expr {[llength $parameters] != 0}] + aa_true "List of parameters is not empty" {[llength $parameters] != 0} array set values [list] @@ -728,7 +728,7 @@ } array unset retrieved_value $parameter } - aa_true "Only the right parameters were retrieved" [expr {[array size retrieved_value] == 0}] + aa_true "Only the right parameters were retrieved" {[array size retrieved_value] == 0} } } @@ -760,7 +760,7 @@ aa_false "Param UseEmailForLoginP 0 -> false" [auth::UseEmailForLoginP] array set elms [auth::get_registration_elements] - aa_false "Registration elements do contain username" [expr {"username" ni [concat $elms(required) $elms(optional)]}] + aa_false "Registration elements do contain username" {"username" ni [concat $elms(required) $elms(optional)]} parameter::set_value -parameter UseEmailForLoginP -package_id [ad_acs_kernel_id] -value {} aa_true "Param UseEmailForLoginP {} -> true" [auth::UseEmailForLoginP] @@ -776,7 +776,7 @@ # GetElements array set elms [auth::get_registration_elements] - aa_true "Registration elements do NOT contain username" [expr {"username" ni [concat $elms(required) $elms(optional)]}] + aa_true "Registration elements do NOT contain username" {"username" ni [concat $elms(required) $elms(optional)]} # Create a user with no username set email [string tolower "[ad_generate_random_string]@foobar.com"] Index: openacs-4/packages/acs-authentication/tcl/test/sync-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-authentication/tcl/test/sync-test-procs.tcl,v diff -u -r1.24 -r1.25 --- openacs-4/packages/acs-authentication/tcl/test/sync-test-procs.tcl 19 Jul 2018 11:49:46 -0000 1.24 +++ openacs-4/packages/acs-authentication/tcl/test/sync-test-procs.tcl 19 Jul 2018 12:15:19 -0000 1.25 @@ -29,7 +29,7 @@ set job_id [auth::sync::job::start \ -authority_id [auth::authority::local]] - aa_true "Returns a job_id" [expr {$job_id ne ""}] + aa_true "Returns a job_id" {$job_id ne ""} # Get doc @@ -62,7 +62,7 @@ # End job array set job [auth::sync::job::end -job_id $job_id] - aa_true "Elapsed time less than 30 seconds" [expr {$job(run_time_seconds) < 30}] + aa_true "Elapsed time less than 30 seconds" {$job(run_time_seconds) < 30} aa_log "Elapsed time: $job(run_time_seconds) seconds" @@ -72,7 +72,7 @@ aa_equals "Number of problems" $job(num_problems) 1 - aa_false "Log URL non-empty" [expr {$job(log_url) eq ""}] + aa_false "Log URL non-empty" {$job(log_url) eq ""} # Purge not deleting the job auth::sync::purge_jobs \ @@ -115,7 +115,7 @@ set job_id [auth::sync::job::start -authority_id [auth::authority::local]] - aa_true "Returns a job_id" [expr {[info exists job_id]}] + aa_true "Returns a job_id" {[info exists job_id]} ##### # @@ -151,7 +151,7 @@ aa_log "entry.message = '$entry(message)'" aa_log "entry.element_messages = '$entry(element_messages)'" - if { [aa_true "Entry has user_id set" [expr {$entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {$entry(user_id) ne ""}] } { set user [acs_user::get -user_id $entry(user_id)] aa_equals "user.first_names" [dict get $user first_names] $user_info(first_names) @@ -188,7 +188,7 @@ aa_equals "entry.success_p" $entry(success_p) "f" - aa_true "entry.message not empty" [expr {$entry(message) ne ""}] + aa_true "entry.message not empty" {$entry(message) ne ""} aa_log "entry.user_id = '$entry(user_id)'" aa_log "entry.message = '$entry(message)'" @@ -225,7 +225,7 @@ aa_log "entry.message = '$entry(message)'" aa_log "entry.element_messages = '$entry(element_messages)'" - if { [aa_true "Entry has user_id set" [expr {$entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {$entry(user_id) ne ""}] } { set user [acs_user::get -user_id $entry(user_id)] aa_equals "user.first_names" [dict get $user first_names] $user_info(first_names) @@ -264,7 +264,7 @@ aa_log "entry.message = '$entry(message)'" aa_log "entry.element_messages = '$entry(element_messages)'" - if { [aa_true "Entry has user_id set" [expr {$entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {$entry(user_id) ne ""}] } { set user [acs_user::get -user_id $entry(user_id)] aa_equals "user.first_names" [dict get $user first_names] $user_info2(first_names) @@ -301,7 +301,7 @@ aa_equals "entry.success_p" $entry(success_p) "f" aa_log "entry.message = '$entry(message)'" if { [aa_true "entry.element_messages not empty" \ - [expr {[info exists entry(element_messages)] && $entry(element_messages) ne ""}]] } { + {[info exists entry(element_messages)] && $entry(element_messages) ne ""}] } { aa_log "entry.element_messages = '$entry(element_messages)'" array unset elm_msgs array set elm_msgs $entry(element_messages) @@ -329,7 +329,7 @@ aa_equals "entry.success_p" $entry(success_p) "t" aa_log "entry.message = '$entry(message)'" - if { [aa_true "Entry has user_id set" [expr {[info exists entry(user_id)] && $entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {[info exists entry(user_id)] && $entry(user_id) ne ""}] } { set member_state [acs_user::get_user_info \ -user_id $entry(user_id) -element "member_state"] aa_equals "User member state is banned" $member_state "banned" @@ -344,15 +344,15 @@ array set job [auth::sync::job::end -job_id $job_id] - aa_true "Elapsed time less than 30 seconds" [expr {$job(run_time_seconds) < 30}] + aa_true "Elapsed time less than 30 seconds" {$job(run_time_seconds) < 30} aa_false "Not interactive" [template::util::is_true $job(interactive_p)] aa_equals "Number of actions" $job(num_actions) 6 aa_equals "Number of problems" $job(num_problems) 2 - aa_false "Log URL non-empty" [expr {$job(log_url) eq ""}] + aa_false "Log URL non-empty" {$job(log_url) eq ""} } } @@ -380,7 +380,7 @@ set job_id [auth::sync::job::start -authority_id [auth::authority::local]] - aa_true "Returns a job_id" [expr {$job_id ne ""}] + aa_true "Returns a job_id" {$job_id ne ""} ##### # @@ -415,7 +415,7 @@ aa_log "entry.message = '$entry(message)'" aa_log "entry.element_messages = '$entry(element_messages)'" - if { [aa_true "Entry has user_id set" [expr {$entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {$entry(user_id) ne ""}] } { set user [acs_user::get -user_id $entry(user_id)] aa_equals "user.first_names" [dict get $user first_names] $user_info(first_names) @@ -457,7 +457,7 @@ aa_log "entry.message = '$entry(message)'" aa_log "entry.element_messages = '$entry(element_messages)'" - if { [aa_true "Entry has user_id set" [expr {$entry(user_id) ne ""}]] } { + if { [aa_true "Entry has user_id set" {$entry(user_id) ne ""}] } { set user [acs_user::get -user_id $entry(user_id)] aa_equals "user.first_names" [dict get $user first_names] $user_info(first_names) @@ -528,7 +528,7 @@ auth::sync::job::get -job_id $job_id -array job aa_log "job.message = '$job(message)'" - aa_true "job.message not empty when called for local authority" [expr {$job(message) ne ""}] + aa_true "job.message not empty when called for local authority" {$job(message) ne ""} } } @@ -712,10 +712,10 @@ aa_true "email has a problem (email missing)" [util_sets_equal_p { email } [array names elm_msgs]] } update { - aa_true "User does not exist" [expr {$entry(message) ne ""}] + aa_true "User does not exist" {$entry(message) ne ""} } delete { - aa_false "Message is not empty" [expr {$entry(message) eq ""}] + aa_false "Message is not empty" {$entry(message) eq ""} } } } @@ -1042,7 +1042,7 @@ aa_equals "result.doc_status is ok" $result(doc_status) "ok" - aa_true "result.doc_message is empty" [expr {$result(doc_message) eq ""}] + aa_true "result.doc_message is empty" {$result(doc_message) eq ""} aa_equals "result.document is 'success'" $result(document) "success" } @@ -1067,7 +1067,7 @@ -call_args [list [list SnapshotPath {} IncrementalPath $path]]] aa_equals "result.doc_status is ok" $result(doc_status) "ok" - aa_true "result.doc_message is empty" [expr {$result(doc_message) eq ""}] + aa_true "result.doc_message is empty" {$result(doc_message) eq ""} aa_equals "result.document is 'success'" $result(document) [template::util::read_file $path] } Index: openacs-4/packages/acs-content-repository/tcl/test/acs-content-repository-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/acs-content-repository-procs.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/acs-content-repository/tcl/test/acs-content-repository-procs.tcl 17 May 2018 14:42:03 -0000 1.6 +++ openacs-4/packages/acs-content-repository/tcl/test/acs-content-repository-procs.tcl 19 Jul 2018 12:16:20 -0000 1.7 @@ -22,10 +22,10 @@ # retrieve the parent's child set new_keyword_id [content::keyword::new -heading $name] - aa_true "created a new content_keyword" [expr {[info exists new_keyword_id] && $new_keyword_id ne ""}] + aa_true "created a new content_keyword" {[info exists new_keyword_id] && $new_keyword_id ne ""} set new_keyword_id_2 [content::keyword::new -heading $name_2 -parent_id $new_keyword_id] - aa_true "created a child content_keyword" [expr {[info exists new_keyword_id_2] && $new_keyword_id_2 ne ""}] + aa_true "created a child content_keyword" {[info exists new_keyword_id_2] && $new_keyword_id_2 ne ""} set children [content::keyword::get_children -parent_id $new_keyword_id ] aa_true "child is returned" [string match "*$new_keyword_id_2*" $children] Index: openacs-4/packages/acs-content-repository/tcl/test/content-folder-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-folder-test-procs.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/acs-content-repository/tcl/test/content-folder-test-procs.tcl 7 Aug 2017 23:47:47 -0000 1.4 +++ openacs-4/packages/acs-content-repository/tcl/test/content-folder-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.5 @@ -40,7 +40,7 @@ content::item::get \ -item_id $first_folder_id \ -array_name first_folder - aa_true "Folder updated" [expr {($first_folder(label) eq "new_label") && ($first_folder(description) eq "new_description")}] + aa_true "Folder updated" {($first_folder(label) eq "new_label") && ($first_folder(description) eq "new_description")} ######################################################### # create a child folder Index: openacs-4/packages/acs-content-repository/tcl/test/content-image-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-image-test-procs.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/acs-content-repository/tcl/test/content-image-test-procs.tcl 7 Aug 2017 23:47:47 -0000 1.6 +++ openacs-4/packages/acs-content-repository/tcl/test/content-image-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.7 @@ -19,7 +19,7 @@ -folder_id $first_folder_id \ -name "test_folder_${first_folder_id}"] aa_true "Folder created" \ - [expr {$first_folder_id == $returned_first_folder_id}] + {$first_folder_id == $returned_first_folder_id} content::folder::register_content_type \ -folder_id $first_folder_id \ @@ -35,7 +35,7 @@ -storage_type "file"] aa_true "First item created $first_item_id" \ - [expr {$first_item_id == $returned_first_item_id}] + {$first_item_id == $returned_first_item_id} # create an image set image_id [db_nextval "acs_object_id_seq"] @@ -46,12 +46,12 @@ -title "Test Title" \ -description "Test Description"] aa_true "Basic Image created revision_id $image_id returned_revision_id $returned_image_id " \ - [expr {$image_id == $returned_image_id}] + {$image_id == $returned_image_id} ::content::item::get_content -revision_id $returned_image_id -array revision_content aa_true "Revision contains correct content" \ - [expr {$revision_content(title) eq "Test Title" - && $image_id == $revision_content(revision_id)}] + {$revision_content(title) eq "Test Title" + && $image_id == $revision_content(revision_id)} content::item::delete -item_id $first_item_id @@ -73,7 +73,7 @@ -folder_id $first_folder_id \ -name "test_folder_${first_folder_id}"] aa_true "Folder created" \ - [expr {$first_folder_id == $returned_first_folder_id}] + {$first_folder_id == $returned_first_folder_id} content::folder::register_content_type \ -folder_id $first_folder_id \ @@ -88,11 +88,11 @@ -name $image_name \ -tmp_filename $tmp_filename] - aa_true "Image Created" [expr {$image_item_id_orig eq $image_item_id}] + aa_true "Image Created" {$image_item_id_orig eq $image_item_id} aa_true "Image CR Item Exists" \ - [expr {$image_item_id eq [content::item::get_id \ + {$image_item_id eq [content::item::get_id \ -item_path $image_name \ - -root_folder_id $first_folder_id]}] + -root_folder_id $first_folder_id]} } } Index: openacs-4/packages/acs-content-repository/tcl/test/content-item-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-item-test-procs.tcl,v diff -u -r1.11 -r1.12 --- openacs-4/packages/acs-content-repository/tcl/test/content-item-test-procs.tcl 7 Aug 2017 23:47:47 -0000 1.11 +++ openacs-4/packages/acs-content-repository/tcl/test/content-item-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.12 @@ -30,7 +30,7 @@ -folder_id $first_folder_id \ -content_type "content_revision" - aa_true "Folder created" [expr {$first_folder_id == $returned_first_folder_id}] + aa_true "Folder created" {$first_folder_id == $returned_first_folder_id} set is_empty [content::folder::is_empty -folder_id $first_folder_id] aa_true "Folder is empty" [string is true $is_empty] @@ -43,7 +43,7 @@ set returned_second_folder_id [content::folder::new \ -folder_id $second_folder_id \ -name "test_folder_${second_folder_id}"] - aa_true "Folder 2 created" [expr {$second_folder_id == $returned_second_folder_id}] + aa_true "Folder 2 created" {$second_folder_id == $returned_second_folder_id} ######################################################### @@ -60,9 +60,9 @@ -attributes [list [list title "$test_name"]] ] - aa_true "First item created" [expr {$first_item_id == $returned_first_item_id}] + aa_true "First item created" {$first_item_id == $returned_first_item_id} - aa_true "first item exists" [expr {[content::item::get -item_id $first_item_id] == 1}] + aa_true "first item exists" {[content::item::get -item_id $first_item_id] == 1} aa_true "First item's revision exists" \ [expr \ @@ -91,7 +91,7 @@ -attributes [list [list title "${evil_test_name}"]] ] - aa_true "Evil_name item created" [expr {$evil_item_id == $returned_evil_item_id}] + aa_true "Evil_name item created" {$evil_item_id == $returned_evil_item_id} aa_true "Evil_name item exists" [expr \ [content::item::get \ @@ -170,11 +170,11 @@ # check that the item exists ######################################################### - aa_true "New Type item created" [expr {$new_type_item_id == $returned_new_type_item_id}] - aa_true "New Type item exists" [expr {[content::item::get \ + aa_true "New Type item created" {$new_type_item_id == $returned_new_type_item_id} + aa_true "New Type item exists" {[content::item::get \ -item_id $new_type_item_id \ -revision "latest" \ - -array_name new_type_item] == 1}] + -array_name new_type_item] == 1} ######################################################### # check that extended attribute exists @@ -193,7 +193,7 @@ -item_id $new_type_item_id \ -revision "latest" \ -array_name new_type_item - aa_true "Item updated $new_type_item(name) $new_type_item(publish_status)" [expr {($new_type_item(name)) eq "new_name" && ($new_type_item(publish_status) eq "live")} ] + aa_true "Item updated $new_type_item(name) $new_type_item(publish_status)" {($new_type_item(name)) eq "new_name" && ($new_type_item(publish_status) eq "live")} ######################################################### # copy it @@ -222,7 +222,7 @@ -item_id $new_type_item_id \ -array_name renamed_item aa_true "Item renamed" \ - [expr {$new_name eq $renamed_item(name)}] + {$new_name eq $renamed_item(name)} ######################################################### @@ -247,14 +247,14 @@ -tmp_filename $::acs::rootdir/packages/acs-content-repository/tcl/test/test.html] aa_true "Tmp_filename added cr_item exists" \ - [expr {[content::item::get_id \ + {[content::item::get_id \ -item_path $tmp_item_name \ -root_folder_id $first_folder_id] \ - eq $tmp_item_id}] + eq $tmp_item_id} aa_true "Tmp_filename added cr_revision exists" \ - [expr {[content::item::get_latest_revision \ - -item_id $tmp_item_id] ne ""}] + {[content::item::get_latest_revision \ + -item_id $tmp_item_id] ne ""} ######################################################### # delete first folder and everything in it to clean up ######################################################### Index: openacs-4/packages/acs-content-repository/tcl/test/content-keyword-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-keyword-test-procs.tcl,v diff -u -r1.3 -r1.4 --- openacs-4/packages/acs-content-repository/tcl/test/content-keyword-test-procs.tcl 7 Aug 2017 23:47:47 -0000 1.3 +++ openacs-4/packages/acs-content-repository/tcl/test/content-keyword-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.4 @@ -26,7 +26,7 @@ # check that keyword_id, heading, description # are set correctly aa_true "Keyword_id assigned" \ - [expr {$assigned_keyword_id == $keyword_id}] + {$assigned_keyword_id == $keyword_id} aa_true "Keyword heading set" \ [string equal "--test_keyword" [content::keyword::get_heading -keyword_id $keyword_id]] aa_true "Keyword description set" \ Index: openacs-4/packages/acs-content-repository/tcl/test/content-revision-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-revision-test-procs.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/acs-content-repository/tcl/test/content-revision-test-procs.tcl 27 Oct 2014 16:39:12 -0000 1.6 +++ openacs-4/packages/acs-content-repository/tcl/test/content-revision-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.7 @@ -20,7 +20,7 @@ -folder_id $first_folder_id \ -name "test_folder_${first_folder_id}"] aa_true "Folder created" \ - [expr {$first_folder_id == $returned_first_folder_id}] + {$first_folder_id == $returned_first_folder_id} content::folder::register_content_type \ -folder_id $first_folder_id \ @@ -35,7 +35,7 @@ -storage_type "text"] aa_true "First item created $first_item_id" \ - [expr {$first_item_id == $returned_first_item_id}] + {$first_item_id == $returned_first_item_id} # create a revision set revision_id [db_nextval "acs_object_id_seq"] @@ -47,14 +47,14 @@ -description "Test Description" \ -content "Test Content"] aa_true "Basic Revision created revision_id $revision_id returned_revision_id $returned_revision_id " \ - [expr {$revision_id == $returned_revision_id}] + {$revision_id == $returned_revision_id} content::item::get_content -revision_id $returned_revision_id -array revision_content set revision_content(content) [cr_write_content -revision_id $returned_revision_id -string] aa_true "Revision contains correct content" \ - [expr { $revision_content(title) eq "Test Title" + { $revision_content(title) eq "Test Title" && $revision_content(content) eq "Test Content" - && $revision_id == $revision_content(revision_id)}] + && $revision_id == $revision_content(revision_id)} content::item::delete -item_id $first_item_id Index: openacs-4/packages/acs-content-repository/tcl/test/content-search-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/tcl/test/content-search-procs.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/acs-content-repository/tcl/test/content-search-procs.tcl 7 Aug 2017 23:47:47 -0000 1.4 +++ openacs-4/packages/acs-content-repository/tcl/test/content-search-procs.tcl 19 Jul 2018 12:16:20 -0000 1.5 @@ -76,12 +76,12 @@ -parent_id $folder_id \ -is_live f] # make sure the item exists first - aa_true "Item exists" [expr {[content::item::get_id \ + aa_true "Item exists" {[content::item::get_id \ -item_path $item_name \ -root_folder_id $folder_id] \ - ne ""}] - aa_true "Item is NOT live" [expr {[content::item::get_live_revision \ - -item_id $item_id] eq ""}] + ne ""} + aa_true "Item is NOT live" {[content::item::get_live_revision \ + -item_id $item_id] eq ""} aa_true "But a revision exists" \ [expr \ {[set latest_revision \ Index: openacs-4/packages/acs-lang/tcl/test/acs-lang-test-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-lang/tcl/test/acs-lang-test-procs.tcl,v diff -u -r1.24 -r1.25 --- openacs-4/packages/acs-lang/tcl/test/acs-lang-test-procs.tcl 11 Jul 2018 10:37:41 -0000 1.24 +++ openacs-4/packages/acs-lang/tcl/test/acs-lang-test-procs.tcl 19 Jul 2018 12:16:20 -0000 1.25 @@ -61,7 +61,7 @@ -enable \ [apm_package_info_file_path $package_key] aa_true "Package install: package enabled" \ - [expr {$package_key in [apm_enabled_packages]}] + {$package_key in [apm_enabled_packages]} } ad_proc -private lang::test::teardown_test_package {} { @@ -116,10 +116,10 @@ $message_actual(upgrade_status) $expect_property(upgrade_status) if {$expect_property(sync_time) eq "not_null"} { aa_true "Import check: $message_key - lang_messages.sync_time not null" \ - [expr {$message_actual(sync_time) ne ""}] + {$message_actual(sync_time) ne ""} } else { aa_true "Import check: $message_key - lang_messages.sync_time null" \ - [expr {$message_actual(sync_time) eq ""}] + {$message_actual(sync_time) eq ""} } } } @@ -555,7 +555,7 @@ set tcl_file_id [open "$::acs::rootdir/$tcl_file" r] set updated_tcl_contents [read $tcl_file_id] close $tcl_file_id - aa_true "tags in Tcl file replaced" [expr {[llength [lang::util::get_temporary_tags_indices $updated_tcl_contents]] == 0}] + aa_true "tags in Tcl file replaced" {[llength [lang::util::get_temporary_tags_indices $updated_tcl_contents]] == 0} # Delete the test message keys foreach message_key [concat [array names messages_array] $expected_new_keys] { @@ -582,15 +582,15 @@ set indices_list [lang::util::get_hash_indices $multilingual_string] set expected_indices_list [list [list 0 14] [list 21 35]] - aa_true "there should be two hash entries" [expr {[llength $indices_list] == 2}] + aa_true "there should be two hash entries" {[llength $indices_list] == 2} set counter 0 foreach index_item $indices_list { set expected_index_item [lindex $expected_indices_list $counter] aa_true "checking start and end indices of item $counter" \ - [expr {[lindex $index_item 0] eq [lindex $expected_index_item 0] - && [lindex $index_item 1] eq [lindex $expected_index_item 1]}] + {[lindex $index_item 0] eq [lindex $expected_index_item 0] + && [lindex $index_item 1] eq [lindex $expected_index_item 1]} set counter [expr {$counter + 1}] } Index: openacs-4/packages/acs-subsite/tcl/test/acs-subsite-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/tcl/test/acs-subsite-procs.tcl,v diff -u -r1.8 -r1.9 --- openacs-4/packages/acs-subsite/tcl/test/acs-subsite-procs.tcl 7 Aug 2017 23:47:58 -0000 1.8 +++ openacs-4/packages/acs-subsite/tcl/test/acs-subsite-procs.tcl 19 Jul 2018 12:16:20 -0000 1.9 @@ -87,7 +87,7 @@ set main_subsite_id [subsite::main_site_id] - aa_true "Main subsite exists" [expr {$main_subsite_id ne ""}] + aa_true "Main subsite exists" {$main_subsite_id ne ""} } } Index: openacs-4/packages/acs-templating/tcl/test/spell-checker-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/tcl/test/spell-checker-procs.tcl,v diff -u -r1.11 -r1.12 --- openacs-4/packages/acs-templating/tcl/test/spell-checker-procs.tcl 27 Jun 2018 09:18:55 -0000 1.11 +++ openacs-4/packages/acs-templating/tcl/test/spell-checker-procs.tcl 19 Jul 2018 12:16:20 -0000 1.12 @@ -51,11 +51,11 @@ return } - aa_true "True statement: Text contains no misspelled words" [expr {$error_num == 0}] + aa_true "True statement: Text contains no misspelled words" {$error_num == 0} aa_log "Number of miss-spelled words found in text: $error_num" - aa_false "False statement: Text contains misspelled word(s)" [expr {$error_num > 0}] + aa_false "False statement: Text contains misspelled word(s)" {$error_num > 0} aa_equals "Number of misspelled words found in text" $error_num 0 @@ -67,7 +67,7 @@ aa_true "The returned string contains no hidden var(s) named 'var_to_spellcheck.error_N', where N is the error number." \ ![regexp "var_to_spellcheck.error_\[0-9\]*" $formtext_to_display] - aa_true "just_the_errwords is empty" [expr {$just_the_errwords eq ""}] + aa_true "just_the_errwords is empty" {$just_the_errwords eq ""} ##### # @@ -86,11 +86,11 @@ return } - aa_true "True statement: Text contains misspelled words" [expr {$error_num > 0}] + aa_true "True statement: Text contains misspelled words" {$error_num > 0} aa_log "Number of misspelled words found in text: $error_num" - aa_false "False statement: Text contains no misspelled word(s)" [expr {$error_num == 0}] + aa_false "False statement: Text contains no misspelled word(s)" {$error_num == 0} aa_log "Returned string: $formtext_to_display" @@ -122,11 +122,11 @@ return } - aa_true "True statement: HTML fragment contains no misspelled words" [expr {$error_num == 0}] + aa_true "True statement: HTML fragment contains no misspelled words" {$error_num == 0} aa_log "Number of miss-spelled words found in HTML fragment: $error_num" - aa_false "False statement: HTML fragment contains misspelled word(s)" [expr {$error_num > 0}] + aa_false "False statement: HTML fragment contains misspelled word(s)" {$error_num > 0} aa_equals "Number of misspelled words found in HTML fragment" $error_num 0 @@ -138,7 +138,7 @@ aa_true "The returned string contains no hidden var(s) named 'var_to_spellcheck.error_N', where N is the error number." \ ![regexp "var_to_spellcheck.error_\[0-9\]*" $formtext_to_display] - aa_true "just_the_errwords is empty" [expr {$just_the_errwords eq ""}] + aa_true "just_the_errwords is empty" {$just_the_errwords eq ""} ##### # @@ -158,11 +158,11 @@ return } - aa_true "True statement: HTML fragment contains misspelled words" [expr {$error_num > 0}] + aa_true "True statement: HTML fragment contains misspelled words" {$error_num > 0} aa_log "Number of miss-spelled words found in HTML fragment: $error_num" - aa_false "False statement: HTML fragment contains no misspelled word(s)" [expr {$error_num == 0}] + aa_false "False statement: HTML fragment contains no misspelled word(s)" {$error_num == 0} aa_log "Returned string: $formtext_to_display" Index: openacs-4/packages/dotlrn-ecommerce/tcl/test/dotlrn-ecommerce-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-ecommerce/tcl/test/dotlrn-ecommerce-procs.tcl,v diff -u -r1.1 -r1.2 --- openacs-4/packages/dotlrn-ecommerce/tcl/test/dotlrn-ecommerce-procs.tcl 20 Apr 2006 20:08:43 -0000 1.1 +++ openacs-4/packages/dotlrn-ecommerce/tcl/test/dotlrn-ecommerce-procs.tcl 19 Jul 2018 12:21:05 -0000 1.2 @@ -21,5 +21,5 @@ -default $param_default \ $param_name] aa_true "Correct default '${param_value}' matches '${param_default}'" \ - [expr {$param_default eq $param_value}] + {$param_default eq $param_value} } \ No newline at end of file Index: openacs-4/packages/dotlrn-fs/tcl/test/dotlrn-fs-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-fs/tcl/test/dotlrn-fs-procs.tcl,v diff -u -r1.3 -r1.4 --- openacs-4/packages/dotlrn-fs/tcl/test/dotlrn-fs-procs.tcl 7 Aug 2017 23:48:10 -0000 1.3 +++ openacs-4/packages/dotlrn-fs/tcl/test/dotlrn-fs-procs.tcl 19 Jul 2018 12:21:05 -0000 1.4 @@ -68,17 +68,17 @@ root_err_msg aa_log $root_err_msg - aa_true "User root folder OK" [expr { + aa_true "User root folder OK" { $check_user_root_folder_id \ - == $user_root_folder_id}] + == $user_root_folder_id} catch {set check_user_shared_folder_id \ [dotlrn_fs::get_user_shared_folder \ -user_id $creation_info(user_id)]} shared_err_msg aa_log $shared_err_msg - aa_true "User shared folder OK" [expr { + aa_true "User shared folder OK" { $check_user_shared_folder_id \ - == $user_shared_folder_id}] + == $user_shared_folder_id} } } Index: openacs-4/packages/dotlrn-weblogger/tcl/test/dotlrn-weblogger-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-weblogger/tcl/test/dotlrn-weblogger-procs.tcl,v diff -u -r1.2 -r1.3 --- openacs-4/packages/dotlrn-weblogger/tcl/test/dotlrn-weblogger-procs.tcl 8 Aug 2006 21:26:40 -0000 1.2 +++ openacs-4/packages/dotlrn-weblogger/tcl/test/dotlrn-weblogger-procs.tcl 19 Jul 2018 12:21:05 -0000 1.3 @@ -93,7 +93,7 @@ } } - aa_false "Non-members $wrong_subs subscribed to $weblogger_package_id in $community_id" [expr {[llength $wrong_subs]>0}] + aa_false "Non-members $wrong_subs subscribed to $weblogger_package_id in $community_id" {[llength $wrong_subs]>0} } # make sure only members are subscribed } Index: openacs-4/packages/assessment/tcl/test/as-assessment-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/test/as-assessment-procs.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/assessment/tcl/test/as-assessment-procs.tcl 7 Aug 2017 23:48:03 -0000 1.5 +++ openacs-4/packages/assessment/tcl/test/as-assessment-procs.tcl 19 Jul 2018 12:24:40 -0000 1.6 @@ -75,11 +75,11 @@ # get data array set assessment_data {} as::assessment::data -assessment_id $assessment_id - aa_true "assessment exists" [expr {$assessment_data(assessment_id) > 0}] + aa_true "assessment exists" {$assessment_data(assessment_id) > 0} # start a session set session_id [as::session::new -assessment_id $assessment_rev_id -subject_id $user_id -package_id $package_id] - aa_true "session exists" [expr {$session_id > 0}] + aa_true "session exists" {$session_id > 0} set section_list [as::assessment::sections -assessment_id $assessment_rev_id \ -session_id $session_id \ @@ -118,7 +118,7 @@ -label $folder_name \ -description $folder_name] aa_true "Folder_id is not null '${folder_id}'" \ - [expr {$folder_id ne ""}] + {$folder_id ne ""} content::folder::register_content_type \ -folder_id $folder_id \ -content_type as_assessments @@ -136,10 +136,10 @@ set assessment_id [ content::revision::item_id -revision_id $assessment_id ] as::assessment::data -assessment_id $assessment_id - aa_true "Item Created " [expr { $title eq $assessment_data(title)}] + aa_true "Item Created " { $title eq $assessment_data(title)} aa_log " $assessment_data(title) " - aa_true "Item Created " [expr { $assessment_data(creator_name) ne ""}] + aa_true "Item Created " { $assessment_data(creator_name) ne ""} aa_log " $assessment_data(creator_name) " } @@ -159,7 +159,7 @@ -label $folder_name \ -description $folder_name] aa_true "Folder_id is not null '${folder_id}'" \ - [expr {$folder_id ne ""}] + {$folder_id ne ""} content::folder::register_content_type \ -folder_id $folder_id \ -content_type as_assessments @@ -179,8 +179,8 @@ set new_revision_id [ as::assessment::edit -assessment_id $assessment_id -title $newtitle ] aa_true "New Title Created" [db_0or1row q "select title from cr_revisions where revision_id=:new_revision_id"] - aa_true "New Title Created - $title " [expr {$title eq $newtitle}] - aa_true "New Title Created - $title not equal to $vartitle" [expr {$title ne $vartitle}] + aa_true "New Title Created - $title " {$title eq $newtitle} + aa_true "New Title Created - $title not equal to $vartitle" {$title ne $vartitle} aa_log "new_revision_id - $new_revision_id" } @@ -201,7 +201,7 @@ -label $folder_name \ -description $folder_name] aa_true "Folder_id is not null '${folder_id}'" \ - [expr {$folder_id ne ""}] + {$folder_id ne ""} content::folder::register_content_type \ -folder_id $folder_id \ -content_type as_assessments @@ -218,7 +218,7 @@ aa_log "assessment_id - $assessment_id" set new_assessment_id [ as::assessment::copy -assessment_id $assessment_id] - aa_true "New Assessment created" [expr { $assessment_id ne $new_assessment_id }] + aa_true "New Assessment created" { $assessment_id ne $new_assessment_id } aa_log "new_assessment_id - $new_assessment_id" } } @@ -237,7 +237,7 @@ -label $folder_name \ -description $folder_name] aa_true "Folder_id is not null '${folder_id}'" \ - [expr {$folder_id ne ""}] + {$folder_id ne ""} content::folder::register_content_type \ -folder_id $folder_id \ -content_type as_assessments @@ -255,7 +255,7 @@ #aa_log "revision_id - $assessment_revision_id" set new_revision_id [ as::assessment::new_revision -assessment_id $assessment_id] - aa_true "New Assessment created" [expr { $assessment_id ne $new_revision_id }] + aa_true "New Assessment created" { $assessment_id ne $new_revision_id } aa_log "new_revision_id - $new_revision_id" } } Index: openacs-4/packages/assessment/tcl/test/as-item-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/test/as-item-procs.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/assessment/tcl/test/as-item-procs.tcl 7 Aug 2017 23:48:03 -0000 1.4 +++ openacs-4/packages/assessment/tcl/test/as-item-procs.tcl 19 Jul 2018 12:24:40 -0000 1.5 @@ -23,7 +23,7 @@ -label $folder_name \ -description $folder_name] aa_true "Folder_id is not null '${folder_id}'" \ - [expr {$folder_id ne ""}] + {$folder_id ne ""} content::folder::register_content_type \ -folder_id $folder_id \ -content_type as_items @@ -42,10 +42,10 @@ } set content [db_string q "select content from cr_revisions where revision_id=:as_item_rev_id"] aa_true "Long title successfully entered" \ - [expr {[string range $long_text 0 999] eq $title}] - aa_true "Long question successfully entered" [expr {$content eq $long_text}] + {[string range $long_text 0 999] eq $title} + aa_true "Long question successfully entered" {$content eq $long_text} aa_true "Mime type is text/html" \ - [expr {$mime_type eq "text/html"}] + {$mime_type eq "text/html"} aa_log "Test item::edit" @@ -54,15 +54,15 @@ aa_true "Item created" [db_0or1row q "select title,mime_type from cr_revisions where revision_id=:new_item_rev_id"] set content [db_string q "select content from cr_revisions where revision_id=:new_item_rev_id"] aa_true "Long title successfully entered" \ - [expr {[string range $long_text 0 999] eq $title}] - aa_true "Long question successfully entered" [expr {$content eq $long_text}] + {[string range $long_text 0 999] eq $title} + aa_true "Long question successfully entered" {$content eq $long_text} aa_log "Test item::new_revision" set new_rev_rev_id [as::item::new_revision -as_item_id $new_item_rev_id] aa_true "Item created" [db_0or1row q "select title,mime_type from cr_revisions where revision_id=:new_rev_rev_id"] set content [db_string q "select content from cr_revisions where revision_id=:new_rev_rev_id"] aa_true "Long title successfully entered" \ - [expr {[string range $long_text 0 999] eq $title}] - aa_true "Long question successfully entered" [expr {$content eq $long_text}] + {[string range $long_text 0 999] eq $title} + aa_true "Long question successfully entered" {$content eq $long_text} aa_log "Test item::copy" set copy_rev_id [as::item::copy \ @@ -71,8 +71,8 @@ aa_true "Item created" [db_0or1row q "select title,mime_type from cr_revisions where revision_id=:copy_rev_id"] set content [db_string q "select content from cr_revisions where revision_id=:copy_rev_id"] aa_true "Long title successfully entered" \ - [expr {[string range $long_text 0 999] eq $title}] - aa_true "Long question successfully entered" [expr {$content eq $long_text}] + {[string range $long_text 0 999] eq $title} + aa_true "Long question successfully entered" {$content eq $long_text} } }