chromium/third_party/blink/web_tests/http/tests/priority-hints/script-preload-scanner-use-counter.html

<script src=resources/common.js></script>
<script src=../resources/testharness.js></script>
<script src=../resources/testharnessreport.js></script>

<!-- Note that Priority Hints take no affect on the pending parsing-blocking
script, as it _must_ be high-prioritized for good user experience -->
<script id="script" src="../resources/dummy.js" fetchpriority="low"></script>

<script>
  const t = async_test('Priority Hints is use-counted when the ' +
                       'fetchpriority content attribute is parsed on ' +
                       '<script>s that are fetched by the preload scanner');

  window.onload = t.step_func_done(() => {
    assert_true(internals.isPreloaded(script.src),
                'The <script> resource was fetched by the preload scanner');
    assert_true(internals.isUseCounted(document, kPriorityHints),
                'Priority Hints is use-counted when the preload scanner ' +
                'fetches a <script> with an fetchpriority attribute');
  });
</script>