chromium/third_party/blink/web_tests/animations/custom-properties/integer-type-interpolation.html

<!DOCTYPE html>
<meta charset="UTF-8">
<style>
.parent {
  --integer: 30;
}
.target {
  --integer: 10;
}
</style>
<body>
<script src="../interpolation/resources/interpolation-test.js"></script>
<script>
CSS.registerProperty({
  name: '--integer',
  syntax: '<integer>',
  initialValue: '40',
  inherits: false,
});

assertInterpolation({
  property: '--integer',
  from: neutralKeyframe,
  to: '20',
}, [
  {at: -0.3, is: '7'},
  {at: 0, is: '10'},
  {at: 0.5, is: '15'},
  {at: 1, is: '20'},
  {at: 1.5, is: '25'},
]);

assertInterpolation({
  property: '--integer',
  from: 'initial',
  to: '20',
}, [
  {at: -0.3, is: '46'},
  {at: 0, is: '40'},
  {at: 0.5, is: '30'},
  {at: 1, is: '20'},
  {at: 1.5, is: '10'},
]);

assertInterpolation({
  property: '--integer',
  from: 'inherit',
  to: '20',
}, [
  {at: -0.3, is: '33'},
  {at: 0, is: '30'},
  {at: 0.5, is: '25'},
  {at: 1, is: '20'},
  {at: 1.5, is: '15'},
]);

assertInterpolation({
  property: '--integer',
  from: 'unset',
  to: '20',
}, [
  {at: -0.3, is: '46'},
  {at: 0, is: '40'},
  {at: 0.5, is: '30'},
  {at: 1, is: '20'},
  {at: 1.5, is: '10'},
]);

assertInterpolation({
  property: '--integer',
  from: '-10',
  to: '10',
}, [
  {at: -0.3, is: '-16'},
  {at: 0, is: '-10'},
  {at: 0.5, is: '0'},
  {at: 1, is: '10'},
  {at: 1.5, is: '20'}
]);

assertInterpolation({
  property: '--integer',
  from: '10',
  to: '15',
}, [
  {at: -0.3, is: '9'},
  {at: 0, is: '10'},
  {at: 0.25, is: '11'},
  {at: 0.5, is: '13'},
  {at: 0.75, is: '14'},
  {at: 1, is: '15'},
  {at: 1.5, is: '18'}
]);
</script>
</body>