You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by Gordon Smith <go...@adobe.com> on 2012/12/01 00:12:28 UTC

RE: Falcon SDKSWCTests

I checked in the beginning of some feature tests for Falcon. Here are my checkin notes.

- Gordon

-------

Falcon: Added simple MXML feature tests for <Boolean>, <int>, <uint>, <Number>, <String>, <Class> and generic instance tags such as <Sprite>. They are not yet part of 'ant tests'.

These tests currently create an MXML file, compile it to a SWF with MXMLC, and check that it compiles cleanly. Soon I'll make the SWF run in Flash Player and check that the runtime asserts don't fire, so that we know that codegen is correct.

Such "feature tests" are intended to test one specific feature of MXML all the way through compilation and execution. By contrast, "unit tests" test only a particular class or subsystem, such as testing the MXML lexer to create MXML tokens, or testing how the MXML parser creates particular kinds of MXML nodes. Furthermore, "functional tests" test real-world situations involving multiple features working together. There are three distinct directories for these various kinds of Falcon tests.

Feature tests do not need to be as exhaustive as the unit tests. For example, suppose we have a complete set of parser tests for the <int> tag and know that ultimately an MXMLLiteralNode gets created with an appropriate int value in each case. Then we do not need to have feature tests for things like integer tags with whitspace around the integer text, or hex integer text, or empty int tags, etc. We can just do a few feature tests that make sure that MXMLLiteralNodes with int values codegen integer values in the VM.

-------

-----Original Message-----
From: Michael Schmalle [mailto:apache@teotigraphix.com] 
Sent: Friday, November 30, 2012 1:36 PM
To: flex-dev@incubator.apache.org
Subject: RE: Falcon SDKSWCTests

Ok we'll meet again next week.

Mike

Quoting Gordon Smith <go...@adobe.com>:

> OK. I'm working on getting a few feature tests in place that test 
> specific features of MXML by compiling to SWF and running in Flash 
> Player. I'm starting with the simplest stuff like a <Boolean> tag. I 
> started working on this two Fridays ago but that was the day that the 
> Haxe discussion ended up taking all day, and then last Friday was a 
> holiday.
>
> - Gordon
>
> -----Original Message-----
> From: Michael Schmalle [mailto:apache@teotigraphix.com]
> Sent: Friday, November 30, 2012 1:23 PM
> To: flex-dev@incubator.apache.org
> Subject: RE: Falcon SDKSWCTests
>
> Gordon,
>
> I entered bugs in JIRA for those, it's actually 2 tickets.
>
> I will fix them. The first one is tricky and a bad set of code I was 
> scared to change without afterwords running mustella.
>
> I had to reformat my computer and haven't got mustella running again.
> Next week I can get on this. I am burnt out from all this js talk. :)
>
> I could go head and start looking at the other SWCs to I am sure Cyril 
> will give them a go as well.
>
> Mike
>
>
> Quoting Gordon Smith <go...@adobe.com>:
>
>> Whoops, the frameworkSWC() compilation test doesn't pass. There are 
>> still four warnings:
>>
>> D:\Apache\incubator\flex\sdk\branches\develop\frameworks\projects\fra
>> m
>> ework\src\mx\collections\ListCollectionView.as:1398
>> Warning: variable definition duplicates function parameter: events.
>> 						var events:Array = updatedItems[j].events;
>> 						    ^
>>
>> D:\Apache\incubator\flex\sdk\branches\develop\frameworks\projects\fra
>> m
>> ework\src\mx\utils\SHA256.as:111
>> Warning: Initializer value 3144134277 for type 'int' must be between
>> -2147483648 and 2147483647 inclusive. An initial value of
>> -1150833019 will be used instead.
>>             var h1:int = 0xbb67ae85;
>>                          ^
>>
>> D:\Apache\incubator\flex\sdk\branches\develop\frameworks\projects\fra
>> m
>> ework\src\mx\utils\SHA256.as:113
>> Warning: Initializer value 2773480762 for type 'int' must be between
>> -2147483648 and 2147483647 inclusive. An initial value of
>> -1521486534 will be used instead.
>>             var h3:int = 0xa54ff53a;
>>                          ^
>>
>> D:\Apache\incubator\flex\sdk\branches\develop\frameworks\projects\fra
>> m
>> ework\src\mx\utils\SHA256.as:115
>> Warning: Initializer value 2600822924 for type 'int' must be between
>> -2147483648 and 2147483647 inclusive. An initial value of
>> -1694144372 will be used instead.
>>             var h5:int = 0x9b05688c;
>>                          ^
>>
>> These are examples of Falcon being pickier (and more correct) than 
>> the old compiler.
>>
>> Any volunteers to fix the source code so that this test passes?
>>
>> - Gordon
>>
>> -----Original Message-----
>> From: Gordon Smith [mailto:gosmith@adobe.com]
>> Sent: Friday, November 30, 2012 1:10 PM
>> To: flex-dev@incubator.apache.org
>> Subject: Falcon SDKSWCTests
>>
>> @Cyril: Thanks for your help with introducing the compile-config.xml 
>> files so that we can more easily make Falcon JUnit tests that compile 
>> each SDK SWC.
>>
>> Now that we have one such test - for compiling framework.swc - 
>> passing, would anybody like to work on investigating the status of 
>> other tests that compile rpc.swc, mx.swc, spark.swc, etc.? We need to 
>> figure out whether the SDK source code needs to change because Falcon 
>> is pickier than the old compiler, or whether Falcon has AS bugs that 
>> need to be fixed.
>>
>> - Gordon
>>
>>
>
> --
> Michael Schmalle - Teoti Graphix, LLC
> http://www.teotigraphix.com
> http://blog.teotigraphix.com
>
>

--
Michael Schmalle - Teoti Graphix, LLC
http://www.teotigraphix.com
http://blog.teotigraphix.com