file_storage::test::delete_first_file (private)

 file_storage::test::delete_first_file -last_request last_request \
    file_name

Defined in packages/file-storage/tcl/test/webtest-procs.tcl

Delete the current file via Web UI.

Switches:
-last_request
(required)
Parameters:
file_name

Partial Call Graph (max 5 caller/called nodes):
%3 aa_log aa_log (public) aa_true aa_true (public) acs::test::find_link acs::test::find_link (public) acs::test::form_reply acs::test::form_reply (public) acs::test::get_form acs::test::get_form (public) file_storage::test::delete_first_file file_storage::test::delete_first_file file_storage::test::delete_first_file->aa_log file_storage::test::delete_first_file->aa_true file_storage::test::delete_first_file->acs::test::find_link file_storage::test::delete_first_file->acs::test::form_reply file_storage::test::delete_first_file->acs::test::get_form

Testcases:
No testcase defined.
Source code:

        #
        # Delete the first displayed file (current rather crude, failure must
        # me detectable from return code).
        #
        set href [acs::test::find_link -last_request $last_request -label {New}]
        aa_log "Download link $href"

        regsub -all /file-add $href /delete href
        regsub -all file_id= $href object_id= href
        aa_log "Delete link $href"
        set d [acs::test::http -last_request $last_request$href]
        acs::test::reply_has_status_code $d 200
        #
        # Get confirm form
        #
        set form [acs::test::get_form [dict get $d body] {//form[@id='delete_confirm']}]
        aa_true "delete confirm form was returned" {[llength $form] > 2}
        set d [::acs::test::form_reply -last_request $d -form $form]
        acs::test::reply_has_status_code $d 302

        return $d
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: