On Sun, Feb 16, 2014 at 4:33 PM, Mark Miesfeld <miesf...@gmail.com> wrote:
> Hi Bert,
>
> The basic answer to your questions here is to discuss something you don't
> understand on the list here.
>
> On Sun, Feb 16, 2014 at 12:46 PM, Bertram Moshier <
> bertrammosh...@gmail.com> wrote:
>
>>
>> At this point the questions those of us participating in the testing
>> program should be asking are:
>>
>> 1) How do we determine the "acceptable" errors and/or failures we can
>> ignore.
>>
>
> Remember what has been said so far in this discussion, check the read me
> first file to see if something in the file covers a failure you see.
>
>
>> 2) How do we determine the "unacceptable" errors and/or failures we need
>> to report.
>>
>
> If you can not understand the failure after considering the read me first
> file and what has been said previously, then discuss it here.
>
>
>> 3) How do we go about learning more about running these tests, so we
>> can make more intelligent decisions and bother you and this list less often.
>>
>
> I think the only way is to do what you have been doing. Use the test
> suite and experiment with it. There is a lot of documentation and examples
> that come with the test suite, you could always read it. Discuss things
> you don't understand on this list.
>
> You can also try to debug a failure on your own. One common technique is
> to pull the test code out of the test group and try to reproduce the
> failure in a small stand alone program.
>
> For instance, I received this report of a failure:
>
> [failure] [20140218 18:30:37.300000]
> svn: r9920 Change date: 2014-02-15 13:19:42 -0800
> Test: TESTSTARTMENU
> Class: SpecialFolders.testgroup
> File:
> D:\ooTest\ooRexx\...\platform\windows\ole\SpecialFolders.testGroup
> Line: 256
> Failed: assertTrue
> Expected: [1]
> Actual: [[0], identityHash="265904242"]
>
> The first thing I did is to look directly at the test. The output is
> designed to help you find exactly what failed. After all, Rick and I need
> to be able to locate the failure. You see the test name: TESTSTARTMENU,
> which test group it is in: SpecialFolders.testGroup, line number in the
> test group, what was expected and what actually happened.
>
> If you look it up in:
>
> ooRexx\extensions\platform\windows\ole\SpecialFolders.testGroup
>
> you find that line 256 is:
>
> self~assertTrue(objFolderItem~name~caselessPos('start menu') > 0)
>
> then it is just a matter of a little intuition or debugging work. Even if
> you do not understand objects, it is not too hard to see that the test is
> looking for the name (of something) to be "start menu", case insensitive.
>
> If you look at the whole test case, you have, note the name of the test
> method is "testStartMenu"
>
> ::method 'testStartMenu'
> objShell = .oleObject~new('Shell.Application')
> sp = 'b'~x2d
> objFolder = objShell~nameSpace(sp)
> objFolderItem = objFolder~self
> self~assertSame(objFolderItem~string,objFolder~Self)
> self~assertNotNull(objFolderItem)
> self~assertNotNull(objFolderItem~name)
> self~assertNotNull(objFolderItem~path)
> self~assertTrue(objFolderItem~name~caselessPos('start menu') > 0)
>
> Even if you do not fully grok objects, it is basically just monkey see,
> monkey do to reduce this to a stand alone program.
>
> I'll also add that Trace ?I added to one of these methods can also be used
to see what is going on. That's frequently my first step for checking out
failures if I can't immediately spot the cause.
Rick
> 1.) Remove the method directive and the asserts that did not fail:
>
> objShell = .oleObject~new('Shell.Application')
> sp = 'b'~x2d
> objFolder = objShell~nameSpace(sp)
> objFolderItem = objFolder~self
>
> self~assertTrue(objFolderItem~name~caselessPos('start menu') > 0)
>
> 2.) Change the assertTrue() to a regular Rexx statement
>
> objShell = .oleObject~new('Shell.Application')
> sp = 'b'~x2d
> objFolder = objShell~nameSpace(sp)
> objFolderItem = objFolder~self
>
> if objFolderItem~name~caselessPos('start menu') > 0 then do
> say 'The name caseless position of start menu is greater than 0'
> end
> else do
> say 'The name caseless position of start menu is NOT greater than 0'
> end
>
> 3.) Turn it into a short program:
>
> /* qTest.rex */
> objShell = .oleObject~new('Shell.Application')
> sp = 'b'~x2d
> objFolder = objShell~nameSpace(sp)
> objFolderItem = objFolder~self
>
> if objFolderItem~name~caselessPos('start menu') > 0 then do
> say 'The name caseless position of start menu is greater than 0'
> end
> else do
> say 'The name caseless position of start menu is NOT greater than 0'
> end
>
> 4.) Run the program and see what happens:
>
> C:\ooTest-4.2.0-snapshot06>qTest.rex
> The name caseless position of start menu is greater than 0
>
> C:\ooTest-4.2.0-snapshot06>
>
> 5.) Maybe add a few intelligent things to help you understand the test
> case:
>
> /* qTest.rex */
> objShell = .oleObject~new('Shell.Application')
> sp = 'b'~x2d
> objFolder = objShell~nameSpace(sp)
> objFolderItem = objFolder~self
>
> say 'The object folder item name is:'
> say ' ' objFolderItem~name
> say
>
> if objFolderItem~name~caselessPos('start menu') > 0 then do
> say 'The name caseless position of start menu is greater than 0'
> end
> else do
> say 'The name caseless position of start menu is NOT greater than 0'
> end
>
> 6.) Run it again:
>
> C:\ooTest-4.2.0-snapshot06>qTest.rex
> The object folder item name is:
> Start Menu
>
> The name caseless position of start menu is greater than 0
>
> C:\ooTest-4.2.0-snapshot06>
>
> At this point you should have some understanding of the test case. And be
> on your way to understanding objects. And see that the test case should
> have worked. At least see that the code works.
>
> If you happened to know that the person who ran the test was using a
> Spanish language version of Windows, you probably could deduce where the
> real problem was.
>
> In addition, to get started understanding how the test cases themselves
> work, you should read the file under doc:
>
> Directory of C:\ooTest-4.2.0-snapshot06\doc
>
> 05/15/2009 08:22 AM 323,731 ooTestQuick.pdf
>
> That PDF is not very big. To gain more insight into the test framework
> itself, there is more doc under the framework sub-directory to help you
> understand ooRexxUnit itself:
>
> Directory of C:\ooTest-4.2.0-snapshot06\framework
>
> 02/16/2014 10:47 AM <DIR> .
> 02/16/2014 10:47 AM <DIR> ..
> 02/16/2014 10:47 AM <DIR> docs
> 02/16/2014 10:47 AM <DIR> example
> 02/16/2014 10:47 AM <DIR> framework.tests
> 04/23/2007 08:28 PM 11,839 CPLv1.0.txt
> 08/22/2008 06:56 PM 18,782 docs-ooRexxUnit.txt
> 11/12/2011 08:25 AM 23,370 FileUtils.cls
> 07/07/2012 11:51 AM 71,129 OOREXXUNIT.CLS
> 06/18/2009 10:16 AM 636 PLEASE.READ
> 08/22/2008 06:56 PM 8,312 runTestUnits.rex
> 01/16/2008 08:11 PM 7,587 WinUtils.cls
> 7 File(s) 141,655 bytes
> 5 Dir(s) 2,205,995,008 bytes free
>
> C:\ooTest-4.2.0-snapshot06>
>
> How you absorb information is of course up to you. But, there is no lack
> of documentation here, both textual and by example. In general I would say
> you need to read the textual documentation along with the examples to get a
> good understanding.
>
> --
> Mark Miesfeld
>
>
>
> ------------------------------------------------------------------------------
> Android apps run on BlackBerry 10
> Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
> Now with support for Jelly Bean, Bluetooth, Mapview and more.
> Get your Android app in front of a whole new audience. Start now.
>
> http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
> _______________________________________________
> Oorexx-users mailing list
> Oorexx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-users
>
>
------------------------------------------------------------------------------
Android apps run on BlackBerry 10
Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
Now with support for Jelly Bean, Bluetooth, Mapview and more.
Get your Android app in front of a whole new audience. Start now.
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users