Back to home

The Aqua Regia Test

Introduction

The expression "Acid Test" comes from the California Gold Rush but for someone who is interested in Web technologies, it refers to the famous Acid2 test. The purpose of this test was to egg on developers to improve the compliance of Web browsers with the CSS2 specification. While the test has clearly been a success from this point of view it also had a dramatic impact: it makes people think that presentation is more important than content. The Acid3 test which checks DOM and ECMAscript capabilities is not likely to improve the situation...

I'm not against testing CSS and Ajax as long as it does not stop progress in the support of other W3C standards. I personally do not want the best design for my website and don't care about all the sophisticated CSS2 properties. At the opposite, I need mathematical formulae but few browsers currently support the MathML language. Of course, you can replace mathematical formulae by any other content you need : musical notation, ruby annotation, charts, slideshow, web forms, right to left text, etc Unfortunately the developers - who are so prude to say their browsers pass Acid2 and who are concentrating their effort on the Acid Test 3 - do not allow some people to express theirselves since their browsers do not support the <ruby> element, MathML formulae, SVG, SMIL, XForms and so forth. Similarly, the webmaster should ask whether it is really useful to have a beautiful website with the state-of-art CSS and Ajax technologies when the content of the pages are not accessible by some people, for instance the blind or people who use a text browser.

In order to make both developers and users aware of the need to improve XML languages support I decided to produce my own acid test - Aqua Regia - which focuses on XHTML+MathML+SVG(+XLink), using a six-year old DTD that main browsers do not completely implement yet. Contrary to the other acid tests, The Aqua Regia Test is not simply designed for browsers with a graphical user interface, but is supposed to be taken by text browsers, browsers with braille or audio output etc. Hence it is not the pixel-by-pixel rendering that is expected but rather to see whether the different browsers and devices can give access to the content of the page.

The structure of Acid Test - i.e. giving a test page with a reference rendering - has been one of the reason of its success: no need to be a specialist of Web technologies to declare that a browser pass the test, a quick look is enough (some people on the internet even use this criteria to claim that a browser is the best or is fully W3C-compliant!). Because this approach seems more difficult when you want to test Web content, I chosed to use a "Quiz": this allows to keep the simplicity of the test and the easy computation of the score. Nevertheless, the purpose of some tests may appear ambiguous without explanation so I give a more precise description of the test-suite for developers, and some screenshots if necessary.

As other tests, Aqua Regia is not exhaustive and since it demonstrates only a small subset of W3C standards it is clearly biased. Consequently, my goal is not to produce a test that will certify the W3C-compliance of a browser but to check another part of the W3C standards that I think more important than CSS+Ajax.

Take the Aqua Regia Test

Which user agents can take the test?

The Aqua Regia is likely to be taken by several kinds of user agent ("classical" browsers, screen readers...). From now on, we call browser a program with the appropriate devices (screen, mouse, keyboard, braille terminal...) that allows somebody to get and understand the content of Web sites. It is also the definition of a user agent that can take the Aqua Regia test. In addition, we add the following distinction:

Note that the definition depends on the way the browser is used. For instance, Amaya and Lynx are respectively V-browser and T-browser, but Amaya in the "alternate view" is a T-browser whereas Lynx used in combination with a screen reader by a blind is a NV-browser.

What does the test-suite check?

Aqua Regia Test focuses on accessibility, internationalization and XML technologies that allow to produce Web content. To pass the test, a browser must at less support the standards below:

A browser does not need to support all the sophisticated features of the languages but must be able to combinate several of them. The test page use the XHTML 1.1 + MathML 2.0 + SVG 1.1 DTD which is still a Working Draft but is currently the only W3C DTD that allows to mixed the languages above and is recognized by the W3C validator.

Description of the test-suite

This section describes the test and explains how the user can get the answers of the Quiz. Note the sometimes you can get the answer without following all the requirements. In this case, it is not considered that your browser passes the test, even if it is indicated in the result page.

Test 1: PNG image and alternate text

Description and requirements

The purpose of this test is to give an information (the color of Aqua Regia) throughout a photograph. To pass the test, V-Browser must be able to display PNG image using the img element. T-Browser and NV-browser must give access to the alternate text and allow user to follow the link to the long description.

How do you get the answer?

Test 2: bidi algorithm and the xml:lang attribute

Description and requirements

The purpose of this test is to check the abilities of your browser for arabic content. The use of arabic characters and the xml:lang attribute allows the browser to guess this is arabic content. The bdo element explicity indicates that the direction of the text content is right to left. To pass the test, V-browser must display something similar to :

Test 2 rendered by a V-browser

Behaviour of T-Browser and NV-Browser ?

How do you get the answer?

Test 3: MathML formulae and chemistry

Description and requirements

This is a simple MathML test. To pass it, V-browser must display msup, msub or mtable according to the rules of presentation MathML. Also, the brace must be streched as you can see in the image below :

Test 3 rendered by a V-browser

Behaviour of T-Browser and NV-Browser ?

How do you get the answer?

The formula of Nitrosyl Chloride is the only one which does not appear in the chemical equation. Thus, even if you do not understand chemistry at all, you can guess the right answer.

Test 4: XLinks in SVG images

Test 5: blockquote, CSS and the xml:lang attribute

Test 6: del, ins and MathML formula

Test 7: Animated SVG

Test 7 rendered by a V-browser

Test 8: MathML formula inside a SVG diagram

Test 8 rendered by a V-browser

Test 9: XLink in MathML formula

Test 9 rendered by a V-browser

Test 10: Ruby annotation and the xml:lang attribute

Test 10 rendered by a V-browser

Test 11: Content MathML

Test 11 rendered by a V-browser

Test 12: XHTML and MathML inside Animated SVG

Description and requirements

This is an SVG image of size 500x400 which is composed of four parts. At the top left corner, a foreign object of size 400x300 contains an XHTML+MathML fragment where the problem is described. There is a grey square of size 100x100 at the bottom right corner that represents a wall. In the remaining area, two other foreignObject of size 100x60 are periodically moved by an SVG animation. These elements contain two mathematical expressions of energy and a use object that refered to a red car. The two cars and the wall are described by a desc element. Here is an example of what a V-browser must displayed (actually, the cars are moving) :

Test 12 rendered by a V-Browser

How do you get the answer?

Using the desc element or seeing the picture, you get the position of the two red cars and identify which one is falling on the wall and which one is hitting it. Then you just have to find the answer in the XHTML+MathML fragment where the problem is described.

References from W3C specifications

  1. Portable Network Graphics (PNG) Specification (Second Edition)
  2. The img element
  3. The alt attribute
  4. The longdesc attribute
  5. The xml:lang attribute
  6. The bdo element
  7. Presentation MathML
  8. Vertical Stretching Rules

Results of some browsers

TODO