<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Syntax Error in Test - Class Method in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672375#M617077</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;a@s,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks so much for the suggestion!  It worked.  I had already created the type as you mentioned, but just hadn't refered to it when defining the table.  I did and it fixed it!!  Now it seems to be working properly  &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Lisa&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Aug 2007 18:06:42 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-08-17T18:06:42Z</dc:date>
    <item>
      <title>Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672371#M617073</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've created a Class, and when I try to test one of the methods (from within SE24), I'm getting the following error:  "Syntax error in test.  Display generated test environment?" (When I say Yes, I'm taken to %_JJ_TESTFRAME_CLASS program)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The strange thing is that the code passed the sytax check, and has been activated.   Additionally, there's no error logged in ST22.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas as to what might cause this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Lisa&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 12:47:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672371#M617073</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T12:47:00Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672372#M617074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you define any private types in your class?. I think you cannot use your own private types with public class attributes. if yes you need to define a table type having line structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a®&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 15:35:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672372#M617074</guid>
      <dc:creator>former_member194669</dc:creator>
      <dc:date>2007-08-17T15:35:25Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672373#M617075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;a@s,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the quick reply.  I do not have anything in either the Protected or Private sections.  Here's the definitions in my Public section:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;public section.

  types TYPE_V_CUST type STRING .
  types TYPE_V_ZIP type STRING .
  types TYPE_V_OFFICE type STRING .
  types TYPE_SHORT type STRING .
  types TYPE_LONG type STRING .
  types TYPE_BDCDATA type BDCDATA .
  types:
    type_table_bdcdata type TABLE OF type_bdcdata .
  types TYPE_V_STATUS_FOUND type STRING .
  types:
    begin of type_statab,
      city_state(30),                   " City/State
      store_location(20),               " Store # or Loc Name
      service_office(20),               " Office Name
      phoned_in_by(20),                 " Phoned/Reported by
      date_phoned_in(10),               " Date phoned in
      response_date(10),                " Response date
      notification type qmel-qmnum,     " Notification #
      po_number type viqmel-bstnk,      " PO number
      invoice_number(80),               " Invoice #
      invoice_amount type vbak-netwr,   " Inv Amt
      invoice_due_date type vbak-erdat, " Inv Due date
      aufnr type aufk-aufnr,            " Service Order #
      text_line type zlbbil_repairs-text_line1,
      END OF type_statab .
  types:
    type_table_statab type TABLE OF type_statab .

  class-data WA_BDCDATA type BDCDATA .
  class-data BDCDATA type TYPE_TABLE_BDCDATA .
  class-data WA_VIQMEL type VIQMEL .
  class-data WA_VBAK type VBAK .
  class-data WA_STATAB type TYPE_STATAB .
  class-data:
    statab TYPE TABLE OF type_statab .

  class-methods CREATE_NOTIF
    importing
      !V_ZIP type TYPE_V_ZIP
      !V_CUST type TYPE_V_CUST
      !V_OFFICE type TYPE_V_OFFICE
      !V_SHORT_TEXT type TYPE_SHORT
      !V_LONG_TEXT type TYPE_LONG
    exporting
      !V_NOTIF_FMT type BAPI2080_NOTHDRE-NOTIF_NO .
  class-methods FILL_BDC_DYNPRO
    importing
      !PROGRAM type BDCDATA-PROGRAM
      !DYNPRO type BDCDATA-DYNPRO .
  class-methods FILL_BDC_FIELD
    importing
      !FNAM type BDCDATA-FNAM
      !FVAL type BDCDATA-FVAL .
  class-methods EMAIL_NOTIF_OFF
    importing
      !V_NOTIF_FMT type BAPI2080_NOTHDRE-NOTIF_NO .
  class-methods EMAIL_NOTIF_CUST
    importing
      !V_NOTIF_FMT type BAPI2080_NOTHDRE-NOTIF_NO
      !V_EMAIL type STRING .
  class-methods GET_NOTIF_STATUS
    importing
      !V_NOTIF type BAPI2080_NOTHDRE-NOTIF_NO
    exporting
      !V_STATUS_FOUND type TYPE_V_STATUS_FOUND .
  class-methods GET_REPAIRS_DONE
    importing
      !WA_VIQMEL type VIQMEL
    changing
      !STATAB type TYPE_TABLE_STATAB
      !WA_STATAB type TYPE_STATAB .&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anything jump out?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 17:05:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672373#M617075</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T17:05:30Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672374#M617076</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Define a table type in Data Dicionary having line structure for &lt;B&gt;&lt;/B&gt;&lt;/P&gt;&lt;P&gt;type_statab&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know this not right , but you can try.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a®&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 17:39:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672374#M617076</guid>
      <dc:creator>former_member194669</dc:creator>
      <dc:date>2007-08-17T17:39:19Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672375#M617077</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;a@s,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks so much for the suggestion!  It worked.  I had already created the type as you mentioned, but just hadn't refered to it when defining the table.  I did and it fixed it!!  Now it seems to be working properly  &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Lisa&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Aug 2007 18:06:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672375#M617077</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-17T18:06:42Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax Error in Test - Class Method</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672376#M617078</link>
      <description>&lt;P&gt;I had the same error and discovered that the cause was a line in my class code that was too long. I declared some local types, and some of the parameters in my methods were defined of that type, so that the whole line of code looked something like this: &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CLASS-METHODS do_something &lt;BR /&gt;IMPORTING iv_parameter_name TYPE zcl_my_long_class_name=&amp;gt;ts_my_structure_type-field_in_structure.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This line of code was too long. I've changed the parameter's type to a dictionary type, made sure that there were no other long lines of code in the class, tried to re-generate the test class environment, and it worked.&lt;/P&gt;</description>
      <pubDate>Sun, 17 Dec 2023 16:02:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/syntax-error-in-test-class-method/m-p/2672376#M617078</guid>
      <dc:creator>cuky</dc:creator>
      <dc:date>2023-12-17T16:02:14Z</dc:date>
    </item>
  </channel>
</rss>

