[mathml] Add unit tests for OpenTypeMathSupport

A platform API for the OpenType MATH table has been added in [1] but
the code is not verified by blink_platform_unittests. This CL adds a
few tests for fonts with or without a MATH table as well as constants
related to script scale down, fractions and radicals. This is not
exhaustive but at least cover all the return statements of
OpenTypeMathSupport::HasMathData and OpenTypeMathSupport::MathConstant.

This also modifies the result of OpenTypeMathSupport::MathConstant
for fonts without a MATH table: Instead of returning HarfBuzz's zero
value, the function returns a null optional so that callers can decide
the default value to use.

[1] https://chromium-review.googlesource.com/c/chromium/src/+/2041485

Bug: 6606, 1050596
Change-Id: I4e7f329bbabb1759f6a1adeaa74b49912812ba8e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2073721
Commit-Queue: Frédéric Wang <fwang@igalia.com>
Reviewed-by: Dominik Röttsches <drott@chromium.org>
Cr-Commit-Position: refs/heads/master@{#744982}
5 files changed