Re: Requirements for (level >=3) tests

2012/2/20 "Gérard Talbot" <css21testsuite@gtalbot.org>:
> Le Lun 20 février 2012 12:31, Aryeh Gregor a écrit :
>> On Fri, Feb 17, 2012 at 3:12 PM, "Gérard Talbot"
>> <css21testsuite@gtalbot.org> wrote:
>>> "Inline styles should not be used unless the case is specifically
>>> testing this scenario."
>>> http://wiki.csswg.org/test/css2.1/format#style-element-embedded-styles
>>
>> What's the reason for this requirement?
>
> Aryeh,
>
> CSS was designed to reuse code, to reduce code and to help create a
> clear separation of structure and presentation. With inline style, you
> have none of these. By adopting such guideline, the test suite is
> promoting best coding practices for CSS.

The point of the test suite is to test implementations.  The tests
must be easily readable, so they can be understood easily, but they
are *not* supposed to be some guide for people to read to learn CSS.
They are horribly suited for that.

>> So I actively prefer inline
>> style.
>
> One single unidentified test is still not a sufficient reason to
> actively choose inline style. Even one thousand identified tests would
> still not be a sufficient reason to.

This is an unwarranted absolutism.  There is nothing inherently wrong
with the style attribute or its use.

I agree with Alan, though - inline styles are easy enough to read when
they set only one or two declarations, but past that they become
somewhat more difficult to read.

In particular, I find your rewritten version of sorting-1a.html harder
to read, because you had to break the @style attribute across two
lines.  I think that simply swapping the #big and #small rules in the
CSS would be sufficient here.

~TJ

Received on Tuesday, 21 February 2012 20:24:33 UTC