@Test
  void testNullAttributeValue() {
    VectorTile vtm = new VectorTile();
    Map<String, Object> attrs = new HashMap<>();
    attrs.put("key1", "value1");
    attrs.put("key2", null);
    attrs.put("key3", "value3");

    vtm.addLayerFeatures("DEPCNT", List.of(
      newVectorTileFeature("DEPCNT", newPoint(3, 6), attrs)
    ));

    byte[] encoded = vtm.encode();
    assertNotSame(0, encoded.length);

    var decoded = VectorTile.decode(encoded);
    assertEquals(List
      .of(new VectorTile.Feature("DEPCNT", 1, VectorTile.encodeGeometry(newPoint(3, 6)), Map.of(
        "key1", "value1",
        "key3", "value3"
      ))), decoded);
    assertSameGeometries(List.of(newPoint(3, 6)), decoded);
  }
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