<?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 Unit Class Test Method will not run in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130768#M1365376</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I created a Test Class in SE24, and created one method with the following code:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
private section.

  methods CREATE_ISTREAM_XSTRING_TEST
  for testing .
  methods SETUP .
  methods TEARDOWN .
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
METHOD create_istream_xstring_test

   CALL METHOD CL_AUNIT_ASSERT=&amp;gt;FAIL
       EXPORTING
         MSG    = 'Deliberate fail'
         LEVEL  = 2
*        QUIT   = METHOD
*        DETAIL =
        .
ENDMETHOD.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For some reason it won't hit this code and the status window informs me that&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unit tests processed successfully; 1 programs, 0 classes, 0 methods&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I run a unit test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why won't the method get executed when testing?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 27 Aug 2009 16:42:14 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-08-27T16:42:14Z</dc:date>
    <item>
      <title>Unit Class Test Method will not run</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130768#M1365376</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I created a Test Class in SE24, and created one method with the following code:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
private section.

  methods CREATE_ISTREAM_XSTRING_TEST
  for testing .
  methods SETUP .
  methods TEARDOWN .
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
METHOD create_istream_xstring_test

   CALL METHOD CL_AUNIT_ASSERT=&amp;gt;FAIL
       EXPORTING
         MSG    = 'Deliberate fail'
         LEVEL  = 2
*        QUIT   = METHOD
*        DETAIL =
        .
ENDMETHOD.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For some reason it won't hit this code and the status window informs me that&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unit tests processed successfully; 1 programs, 0 classes, 0 methods&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I run a unit test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why won't the method get executed when testing?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Aug 2009 16:42:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130768#M1365376</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-27T16:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Unit Class Test Method will not run</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130769#M1365377</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have you created your a Local test class inherited from this Global Test class?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Steps to consider:&lt;/P&gt;&lt;P&gt;1. Create a Global Test class&lt;/P&gt;&lt;P&gt;2. Create a Model Class which has all your main logic&lt;/P&gt;&lt;P&gt;3. Create a Local test class inherited from the Global Test Class (cerated in Step 1)&lt;/P&gt;&lt;P&gt;4. Now try to do the unit test in the Model Class&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Aug 2009 16:45:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130769#M1365377</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2009-08-27T16:45:22Z</dc:date>
    </item>
    <item>
      <title>Re: Unit Class Test Method will not run</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130770#M1365378</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;I solved the problem by using the Wizard to crate an ABAP Unit test class.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tony.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Anthony Bateman on Aug 28, 2009 12:31 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Aug 2009 09:30:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/unit-class-test-method-will-not-run/m-p/6130770#M1365378</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-28T09:30:55Z</dc:date>
    </item>
  </channel>
</rss>

