fune/dom/base/test/file_use_counter_appearance.html
Cameron McCormack acbe938068 Bug 1642261 - Part 3: Refactor browser_use_counters.js. r=emilio
This refactoring achieves a few things:

1. Removing the duplication between the different check_use_counter_xxx
   functions.
2. Increasing the number of repetitions that
   BrowserTestUtils.waitForCondition uses so that we have intermittently
   failures resulting from it reaching its maximum repetitions.
3. Checking all telemetry histograms from the one document at once,
   rather than re-loading the document for each histogram checked.
   (This saves a lot of time, and was the cause of macOS timeouts after
   the -moz-appearance use counter checks were added.)
4. A change to use a CSS property use counter as a sentinel to determine
   whether telemetry has been reported yet, rather than the number of
   documents destroyed, since the browser might be loading various other
   documents in the background that can cause us to advance the test
   before telemetry has been reported.

Differential Revision: https://phabricator.services.mozilla.com/D78416
2020-06-05 08:34:36 +00:00

33 lines
1.1 KiB
HTML

<!DOCTYPE html>
<!-- a value set by the UA sheet -->
<button>a button</button>
<!-- a value set on a widget that normally has that appearance -->
<input style="-moz-appearance: textfield;">
<!-- a value set on a widget that doesn't normally have that appearance -->
<input type="radio" style="-moz-appearance: checkbox;">
<!-- a value set on a non-widget -->
<div style="-moz-appearance: menulist-button;"></div>
<!-- a standard value set on a widget that normally has that appearance, cascading over some other value -->
<style>
textarea { -moz-appearance: meter; }
textarea { -moz-appearance: textarea; }
</style>
<textarea></textarea>
<!-- a non-standard value set on a widget that normally has that appearance, cascading over some other value -->
<style>
input[type=range] { -moz-appearance: none; }
input[type=range] { -moz-appearance: range; }
</style>
<input type="range">
<!-- a non-standard value set by UA sheets, which we want to track for cascading over some other value -->
<input type="number">
<!-- Sentinel use counter to signal that telemetry for this document has been captured -->
<style>x { marker-mid: initial; }</style>