Updated to address Max's review comments:

On 2010-04-21, at 15:17, Max Carlson wrote:

> Metasuite passes with two compiler errors:
> 
> constraints/constraint-test.lzx:65:67: The attribute 'width' has a 
> non-constant $style binding, which is not supported

Forgot to update changeset.  Fixed.

> resource/resource-not-found.lzx:35:44: Can't import /resource/main.lzx: Can't 
> import /resource/main.lzx: bad mime type

That's expected isn't it?  The comment on the line before says:

>     <!-- if we give a null value for the resource's src attribute, we
>        get a compiler warning, which is correct behavior. -->

I'm just going to comment out the tests that produce "known" compiler errors.

> test/style/constraints/main.lzx has this error:
> constraints/constraint-test.lzx:65:67: The attribute 'width' has a 
> non-constant $style binding, which is not supported

Same as above.

> And fails this test:
> ERROR: perry should have an x of 0:  expected 0 got (void 0)
> 
> I'm not sure why metasuite doesn't completely include the entire set of 
> constraint tests, so that should be fixed and the warnings/errors cleaned up.

It was just missing the 'contention' test.  I think only because this whole 
suite is kind of a mess.  Probably Ben wanted to be able to test each 
individually.  He should have had a main in each one that just included a 
library and the library could be shared between main and meta.

Ok, I actually did that, and more:  I remodularized the whole css test suite so 
that each sub-test is entirely in a library file.  The subtests have main 
driver files that just include the library, and the metasuite includes the 
libraries of all the subtests.

I had to tweak lzunit just slightly to allow multiple TestSuite's to share a 
single test display.  While I was there I created a better fix to ensure that 
the lzunit display is in front of any test views but does not obscure the 
debugger console window.

The style tests now pass with no errors.  And the smokecheck still passes.

---

Change 20100421-ptw-K by [email protected] on 2010-04-21 11:05:04 EDT
    in /Users/ptw/OpenLaszlo/trunk
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: No more dynamically computed CSS style property names

Bugs Fixed: LPP-8925 Remove support for dynamically computed CSS style property 
names

Technical Reviewer: [email protected] (pending)
QA Reviewer: [email protected] (pending)

Overview:

    No one ever uses `value=$style{<random string-valued
    expression>}`, it is uneccesary generality and prevents us from
    optimizing style constraints.  The new syntax `style="propname"`
    is much more streamlined and allows you to specify a fallback
    value when there is no applicable CSS binding.

Details:

    NodeModel:  Signal an error if the value of a $style constraint is
    not a constant string.

    constraint-test: Remove the obsolete test case, replace it with a
    new style example.

    test/style/*:  Remodularize the individual tests to be in library
    files which can be uniformly included in the metasuite, to ensure
    there is not a skew between the individual tests and the
    metasuite.

    debugger:  In ensureVisible, always bring yourself to the front,
    since you can't tell when someone else may have intervened.

    lzunit:  Create a single display for the results on the canvas so
    you can have multiple suites in a test all reporting to one
    place.  Ensure that that display is the frontmost view, overlaying
    any actual test views, but don't put yourself in front of the
    debug console window

Tests:
    smokecheck, test/style/metasuite.lzx

Files:
M       test/style/resource/main.lzx
A       test/style/resource/library.lzx
M       test/style/resource/resource-not-found.lzx
M       test/style/merging/main.lzx
A       test/style/merging/library.lzx
M       test/style/simple/main.lzx
M       test/style/simple/undefineds.lzx
A       test/style/simple/library.lzx
M       test/style/simple/simple.lzx
M       test/style/elementselector/main.lzx
A       test/style/elementselector/library.lzx
M       test/style/idselector/main.lzx
A       test/style/idselector/library.lzx
M       test/style/suite.lzx
M       test/style/constraints/main.lzx
A       test/style/constraints/library.lzx
M       test/style/constraints/contention.lzx
M       test/style/constraints/speedtest.lzx
M       test/style/constraints/constraint-test.lzx
A       test/style/neighborhood/library.lzx
M       test/style/descendantselector/main.lzx
A       test/style/descendantselector/library.lzx
M       test/style/descendantselector/descendantselector-test.lzx
M       test/style/compiler/main.lzx
A       test/style/compiler/library.lzx
M       test/style/attrselector/main.lzx
A       test/style/attrselector/library.lzx
M       test/style/attrselector/attrs.lzx
M       test/style/attrselector/name-test.lzx
A       test/style/specificity/library.lzx
M       test/style/specificity/specificity-tests.lzx
M       test/style/metasuite.lzx
M       WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java
M       lps/components/debugger/debugger.lzx
M       lps/components/lzunit/lzunit.lzx

Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20100421-ptw-K.tar

Reply via email to