_acs-tcl__ad_html_to_text_image (private)

 _acs-tcl__ad_html_to_text_image

Defined in packages/acs-tcl/tcl/test/html-conversion-procs.tcl

Partial Call Graph (max 5 caller/called nodes):
%3 aa_log aa_log (public) aa_log_result aa_log_result (public) aa_true aa_true (public) ad_html_to_text ad_html_to_text (public) _acs-tcl__ad_html_to_text_image _acs-tcl__ad_html_to_text_image _acs-tcl__ad_html_to_text_image->aa_log _acs-tcl__ad_html_to_text_image->aa_log_result _acs-tcl__ad_html_to_text_image->aa_true _acs-tcl__ad_html_to_text_image->ad_html_to_text

Testcases:
No testcase defined.
Source code:
        
        set _aa_export {}
        set body_count 1
        foreach testcase_body {{
    set html {
        This is a text with a regular image <img src="/images/foo.png">,
        image with alt text <img src="/images/bar.png" alt="flower">,
        and an embedded image <img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEU..."
        alt='embedded'>.
    }
    set result [ad_html_to_text -- $html]
    aa_log "<pre>$result</pre>"
    aa_true "contains image" [string match {*\[IMAGE: /images*} $result]
    aa_true "contains alt text" [string match {*\[IMAGE: 'flower'*} $result]
    aa_true "contains embedded image abbreviated" [string match {*\[IMAGE:*data:...*} $result]
}} {
          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" "ad_html_to_text_image (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: