Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  test_attrchange.html   Sprache: HTML

 
 products/Sources/formale Sprachen/C/Firefox/accessible/tests/mochitest/events/test_attrchange.html


<html>

<head>
  <title>Accessible attr change event testing</title>

  <link rel="stylesheet" type="text/css"
        href="chrome://mochikit/content/tests/SimpleTest/test.css" />

  <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>

  <script type="application/javascript"
          src="../common.js"></script>
  <script type="application/javascript"
          src="../promisified-events.js"></script>
  <script type="application/javascript"
          src="../role.js"></script>
  <script type="application/javascript"
          src="../states.js"></script>

  <script type="application/javascript">
    async function testGotAttrChange(elem, name, value) {
      const waitFor = waitForEvent(EVENT_OBJECT_ATTRIBUTE_CHANGED, elem);
      if (value) {
        document.getElementById(elem).setAttribute(name, value);
      } else {
        document.getElementById(elem).removeAttribute(name);
      }
      await waitFor;
    }

    async function doTests() {
      info("Removing summary attr");
      // after summary is removed, we should have a layout table
      await testGotAttrChange(
        "sampleTable",
        "summary",
        null
        );

      info("Setting abbr attr");
      // after abbr is set we should have a data table again
      await testGotAttrChange(
        "cellOne",
        "abbr",
        "hello world"
        );

      info("Removing abbr attr");
      // after abbr is removed we should have a layout table again
      await testGotAttrChange(
        "cellOne",
        "abbr",
        null
        );

      info("Setting scope attr");
      // after scope is set we should have a data table again
      await testGotAttrChange(
        "cellOne",
        "scope",
        "col"
        );

      info("Removing scope attr");
      // remove scope should give layout
      await testGotAttrChange(
        "cellOne",
        "scope",
        null
        );

      info("Setting headers attr");
      // add headers attr should give data
      await testGotAttrChange(
        "cellThree",
        "headers",
        "cellOne"
        );

      info("Removing headers attr");
      // remove headers attr should give layout
      await testGotAttrChange(
        "cellThree",
        "headers",
        null
        );

      SimpleTest.finish();
    }

    SimpleTest.waitForExplicitFinish();
    addA11yLoadEvent(doTests);
  </script>
</head>
<body>
  <table id="sampleTable" summary="example summary">
      <tr>
        <td id="cellOne">cell1</td>
        <td>cell2</td>
      </tr>
      <tr>
        <td id="cellThree">cell3</td>
        <td>cell4</td>
      </tr>
    </table>
</body>
</html>

Messung V0.5
C=97 H=97 G=96

¤ Dauer der Verarbeitung: 0.13 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge