private PlanetilerResults run(
    Map<String, String> args,
    Runner runner,
    Profile profile
  ) throws Exception {
    PlanetilerConfig config = PlanetilerConfig.from(Arguments.of(args));
    FeatureGroup featureGroup = FeatureGroup.newInMemoryFeatureGroup(TileOrder.TMS, profile, config, stats);
    runner.run(featureGroup, profile, config);
    featureGroup.prepare();
    try (Mbtiles db = Mbtiles.newInMemoryDatabase(config.arguments())) {
      TileArchiveWriter.writeOutput(featureGroup, db, () -> 0L, new TileArchiveMetadata(profile, config),
        null, config, stats);
      var tileMap = TestUtils.getTileMap(db);
      tileMap.values().forEach(fs -> fs.forEach(f -> f.geometry().validate()));
      int tileDataCount = db.compactDb() ? TestUtils.getTilesDataCount(db) : 0;
      return new PlanetilerResults(tileMap, db.metadata().toMap(), tileDataCount);
    }
  }
In-memory tests with fake data and profiles to ensure all features work end-to-end.
planetiler-core/src/test/java/com/onthegomap/planetiler/PlanetilerTests.java