_calendar__attachments_enabled (private)

 _calendar__attachments_enabled

Defined in packages/calendar/tcl/test/calendar-procs.tcl

Partial Call Graph (max 5 caller/called nodes):
%3 aa_false aa_false (public) aa_log aa_log (public) aa_log_result aa_log_result (public) aa_run_with_teardown aa_run_with_teardown (public) aa_true aa_true (public) _calendar__attachments_enabled _calendar__attachments_enabled _calendar__attachments_enabled->aa_false _calendar__attachments_enabled->aa_log _calendar__attachments_enabled->aa_log_result _calendar__attachments_enabled->aa_run_with_teardown _calendar__attachments_enabled->aa_true

Testcases:
No testcase defined.
Source code:
        
        set _aa_export {}
        set body_count 1
        foreach testcase_body {{
    set old_package_id [ad_conn package_id]

    aa_run_with_teardown -rollback -test_code {
        set safe_name [db_string q {select max(name) || 'z' from site_nodes}]
        set package_id [site_node::instantiate_and_mount -package_key calendar -node_name $safe_name]

        ad_conn -set package_id ""
        aa_false "No attachments on the new calendar instance (with package)"  [calendar::attachments_enabled_p -package_id $package_id]

        ad_conn -set package_id $package_id
        aa_false "No attachments on the new calendar instance" [calendar::attachments_enabled_p]

        set node [site_node::get_from_object_id -object_id $package_id]
        set node_id [dict get $node node_id]

        site_node::instantiate_and_mount -package_key attachments -parent_node_id $node_id

        ad_conn -set package_id ""
        aa_true "Attachments are available (with package)"  [calendar::attachments_enabled_p -package_id $package_id]

        ad_conn -set package_id $package_id
        aa_true "Attachments are available" [calendar::attachments_enabled_p]

        ad_conn -set package_id $old_package_id
    } -teardown_code {
        ad_conn -set package_id $old_package_id
    }
}} {
          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" "attachments_enabled (body $body_count): Error during execution: $msg, stack trace: \n$::errorInfo"
          }
          incr body_count
        }
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: