@Test
  void testFilterPointsOutsideBuffer() {
    assertArrayEquals(
      new int[0],
      VectorTile.encodeGeometry(newPoint(-5, -5))
        .filterPointsOutsideBuffer(4).commands()
    );
    assertArrayEquals(
      new int[]{
        VectorTile.Command.MOVE_TO.value | (1 << 3),
        zigZagEncode((int) (-5d * 4096 / 256)),
        zigZagEncode((int) (-5d * 4096 / 256)),
      },
      VectorTile.encodeGeometry(newPoint(-5, -5))
        .filterPointsOutsideBuffer(5).commands()
    );
  }
This class is copied from
https://github.com/ElectronicChartCentre/java-vector-tile/blob/master/src/test/java/no/ecc/vectortile/VectorTileEncoderTest.java
and modified based on the changes in VectorTileEncoder, and adapted to junit 5.
planetiler-core/src/test/java/com/onthegomap/planetiler/VectorTileTest.java