(tmpdir, data, minzoom, maxzoom, exp_num_tiles, source)
| 231 | ], |
| 232 | ) |
| 233 | def test_export_count(tmpdir, data, minzoom, maxzoom, exp_num_tiles, source): |
| 234 | inputfile = str(data.join(source)) |
| 235 | outputfile = str(tmpdir.join("export.pmtiles")) |
| 236 | runner = CliRunner() |
| 237 | result = runner.invoke( |
| 238 | main_group, |
| 239 | [ |
| 240 | "pmtiles", |
| 241 | "--zoom-levels", |
| 242 | "{}..{}".format(minzoom, maxzoom), |
| 243 | inputfile, |
| 244 | outputfile, |
| 245 | ], |
| 246 | ) |
| 247 | assert result.exit_code == 0 |
| 248 | with open(outputfile, 'rb') as f: |
| 249 | src = MmapSource(f) |
| 250 | assert len(list(all_tiles(src))) == exp_num_tiles |
| 251 | |
| 252 | |
| 253 | @pytest.mark.parametrize("filename", ["RGBA.byte.tif"]) |
nothing calls this directly
no test coverage detected
searching dependent graphs…