From d10612f94b1ef724c0f924a901df3160703e8c7c Mon Sep 17 00:00:00 2001 From: jvelilla Date: Wed, 2 Dec 2015 10:56:18 -0300 Subject: [PATCH] Made test.ecf compilable. --- library/gcse/src/gcse_page_item.e | 111 +++++++++++++++--------------- library/gcse/test/application.e | 20 +++--- library/gcse/test/test.ecf | 1 - 3 files changed, 65 insertions(+), 67 deletions(-) diff --git a/library/gcse/src/gcse_page_item.e b/library/gcse/src/gcse_page_item.e index 7e5426c..97d6b1d 100644 --- a/library/gcse/src/gcse_page_item.e +++ b/library/gcse/src/gcse_page_item.e @@ -7,7 +7,6 @@ class GCSE_PAGE_ITEM inherit - DEBUG_OUTPUT feature -- Access @@ -139,62 +138,62 @@ feature -- Element change feature -- Output - debug_output: STRING_8 - -- - do - create Result.make_from_string ("%NPage Item details%N") - if attached title as l_title then - Result.append ("Title:") - Result.append (l_title) - Result.append_character ('%N') - end - if attached kind as l_kind then - Result.append ("Kind:") - Result.append (l_kind) - Result.append_character ('%N') - end - if attached html_title as l_html_title then - Result.append ("Html title:") - Result.append (l_html_title) - Result.append_character ('%N') - end - if attached link as l_link then - Result.append ("Link:") - Result.append (l_link) - Result.append_character ('%N') - end - if attached display_link as l_display_link then - Result.append ("Display link:") - Result.append (l_display_link) - Result.append_character ('%N') - end - if attached snippet as l_snippet then - Result.append ("Snippet:") - Result.append (l_snippet) - Result.append_character ('%N') - end - if attached html_snippet as l_html_snippet then - Result.append ("Html snippet:") - Result.append (l_html_snippet) - Result.append_character ('%N') - end - if attached cache_id as l_cache_id then - Result.append ("Cache_id:") - Result.append (l_cache_id) - Result.append_character ('%N') - end - if attached formatted_url as l_formatted_url then - Result.append ("Formatted url:") - Result.append (l_formatted_url) - Result.append_character ('%N') - end - if attached html_formatted_url as l_html_formatted_url then - Result.append ("Html formatted url:") - Result.append (l_html_formatted_url) - Result.append_character ('%N') - end - + debug_output: STRING_8 + -- + do + create Result.make_from_string ("%NPage Item details%N") + if attached title as l_title then + Result.append ("Title:") + Result.append (l_title) + Result.append_character ('%N') end + if attached kind as l_kind then + Result.append ("Kind:") + Result.append (l_kind) + Result.append_character ('%N') + end + if attached html_title as l_html_title then + Result.append ("Html title:") + Result.append (l_html_title) + Result.append_character ('%N') + end + if attached link as l_link then + Result.append ("Link:") + Result.append (l_link) + Result.append_character ('%N') + end + if attached display_link as l_display_link then + Result.append ("Display link:") + Result.append (l_display_link) + Result.append_character ('%N') + end + if attached snippet as l_snippet then + Result.append ("Snippet:") + Result.append (l_snippet) + Result.append_character ('%N') + end + if attached html_snippet as l_html_snippet then + Result.append ("Html snippet:") + Result.append (l_html_snippet) + Result.append_character ('%N') + end + if attached cache_id as l_cache_id then + Result.append ("Cache_id:") + Result.append (l_cache_id) + Result.append_character ('%N') + end + if attached formatted_url as l_formatted_url then + Result.append ("Formatted url:") + Result.append (l_formatted_url) + Result.append_character ('%N') + end + if attached html_formatted_url as l_html_formatted_url then + Result.append ("Html formatted url:") + Result.append (l_html_formatted_url) + Result.append_character ('%N') + end + + end note copyright: "2011-2015 Javier Velilla, Jocelyn Fiat, Eiffel Software and others" diff --git a/library/gcse/test/application.e b/library/gcse/test/application.e index bdc9b06..14c7d46 100644 --- a/library/gcse/test/application.e +++ b/library/gcse/test/application.e @@ -1,7 +1,7 @@ note description : "test application root class" - date : "$Date: 2015-10-08 07:51:29 -0300 (ju., 08 oct. 2015) $" - revision : "$Revision: 97966 $" + date : "$Date: 2015-12-02 10:27:38 -0300 (mi. 02 de dic. de 2015) $" + revision : "$Revision: 98180 $" class APPLICATION @@ -27,20 +27,20 @@ feature {NONE} -- Initialization if attached {GCSE_RESPONSE} gcse.last_result as l_result then if attached l_result.current_page as l_page then print ("Current Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.next_page as l_page then print ("Next Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.previous_page as l_page then print ("Previous Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.items as l_items then print ("Number of items:" + l_items.count.out) - across l_items as ic loop print (ic.item.to_string) end + across l_items as ic loop print (ic.item.debug_output) end end if attached l_result.next_page as l_page then @@ -52,20 +52,20 @@ feature {NONE} -- Initialization if attached {GCSE_RESPONSE} gcse.last_result as l_result then if attached l_result.current_page as l_page then print ("Current Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.next_page as l_page then print ("Next Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.previous_page as l_page then print ("Previous Page%N") - print (l_page.to_string) + print (l_page.debug_output) end if attached l_result.items as l_items then print ("Number of items:" + l_items.count.out) - across l_items as ic loop print (ic.item.to_string) end + across l_items as ic loop print (ic.item.debug_output) end end end diff --git a/library/gcse/test/test.ecf b/library/gcse/test/test.ecf index 0db0a14..eb24953 100644 --- a/library/gcse/test/test.ecf +++ b/library/gcse/test/test.ecf @@ -6,7 +6,6 @@ -