style: Move size of tests to compile-time tests in the style crate

Same reasoning as the previous commit.

Differential Revision: https://phabricator.services.mozilla.com/D146104
This commit is contained in:
Emilio Cobos Álvarez 2023-08-14 22:05:25 +02:00 committed by Martin Robinson
parent 50d31686be
commit f48b95e2e3
13 changed files with 53 additions and 49 deletions

View file

@ -31,6 +31,9 @@ pub use specified::ImageRendering;
pub type Image =
generic::GenericImage<Gradient, MozImageRect, ComputedImageUrl, Color, Percentage, Resolution>;
// Images should remain small, see https://github.com/servo/servo/pull/18430
size_of_test!(Image, 16);
/// Computed values for a CSS gradient.
/// <https://drafts.csswg.org/css-images/#gradients>
pub type Gradient = generic::GenericGradient<

View file

@ -39,6 +39,9 @@ use style_traits::{SpecifiedValueInfo, StyleParseErrorKind, ToCss};
pub type Image =
generic::Image<Gradient, MozImageRect, SpecifiedImageUrl, Color, Percentage, Resolution>;
// Images should remain small, see https://github.com/servo/servo/pull/18430
size_of_test!(Image, 16);
/// Specified values for a CSS gradient.
/// <https://drafts.csswg.org/css-images/#gradients>
pub type Gradient = generic::Gradient<