flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maurice Amsellem <maurice.amsel...@systar.com>
Subject RE: Debugging Mustella tests in Flash Builder
Date Mon, 14 Oct 2013 23:10:02 GMT
That's fantastic!! Thanks a lot for the explanations.

I think this should end "as is" in the WIKI.

Maurice 

-----Message d'origine-----
De : omuppi1@gmail.com [mailto:omuppi1@gmail.com] De la part de OmPrakash Muppirala
Envoyé : mardi 15 octobre 2013 01:01
À : dev@flex.apache.org
Objet : Debugging Mustella tests in Flash Builder

On Mon, Oct 14, 2013 at 3:02 PM, Maurice Amsellem < maurice.amsellem@systar.com> wrote:

> > You can try the opening-fb-debugger and then running the debug swf
> trick.  Let me know if you need more details on how to do this.
>
> Yes please.
>

I just tried these steps and they work:

1.  Create a Web Flex Project called MustellaDebug.  It does not matter which version of Flex
compiler you chose.
2.  Right click project > Flex Build Path > Source path 3.  Add the path to the Mustella
test directory you want to debug.  In this example, I will use this path: <my
path>\git\flex-sdk\mustella\tests\components\DataGrid\DataGrid_SparkSkin
path>\Properties
For this example, I will chose the test:
tests/components/DataGrid/DataGrid_SparkSkin/Properties/datagrid_properties_columns.mxml
4.  In Flash Builder,
    Open the file [source
path]DataGrid_SparkSkin/Properties/datagrid_properties_columns.mxml and set a breakpoint on
Line: 65
    Open the file [source path]DataGrid_SparkSkin/SWFs/DataGridApp.mxml and set a breakpoint
on Line: 530

5.  Create a file called debug.html in your bin-debug directory.  Leave this file empty.
6.  Under the debug menu, select 'Debug Configurations...' item 7.  Create a new 'Web  Application'
run configuration 8.  On the right side, select your 'Project' and ''Applicaton'' file based
on the MustellaTest app.
9.  For "URL or Path to launch", uncheck the Úse default' option 10.  Give the path to the
debug.html file under your bin-debug directory.
11.  Click Apply to save the debug configuration.

12.  If you dont have the swf file for the test alread created, run the mini_run script like
this from the commandline/cygwin:
$ ./mini_run.sh -caseName=datagrid_properties_columns_0
tests/components/DataGrid/DataGrid_SparkSkin/Properties/datagrid_properties_columns.mxml
This will create the DataGridApp.swf file in the SWFs folder

13.  Back in Flash Builder click Debug.  This will launch the FB debugger which will start
waiting for a connection.
14.  Now, open the DataGridApp.swf in a debug flash player.
15.  Right click on the running swf file and select the 'Debugger' menu item.
16.  You will be prompted to chose which Debugger to connect to.  Select 'Localhost'.
17.  Now, your Flash Builder's debugger will connect to the running swf and you should be
able to debug inside the IDE.
18.  Going forward, every time you want to debug the swf, first launch the debug.html configuration
before loading the swf.



>
> Also, how is it possible to run only one test case ?
> Eg.  DataGrid_requireSelection_test001 > requireSelection_test15 
> instead of the full DataGrid/Properties mini_run?
> Or at least, all the test cases in DataGrid_requireSelection_test001?
>

As mentioned in the above example, you could run it like this:
$ ./mini_run.sh -caseName=DataGrid_requireSelection_test001
tests/gumbo/components/DataGrid/Properties/DataGrid_requireSelection_test001.mxml

Hope this helps.

Thanks,
Om

Mime
View raw message