@flighthq/tilemap-formats 0.3.1-next.948.85d9f30 → 0.3.1-next.970.9691e7b

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flighthq/tilemap-formats",
3
- "version": "0.3.1-next.948.85d9f30",
3
+ "version": "0.3.1-next.970.9691e7b",
4
4
  "author": "Joshua Granick and other contributors",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -38,10 +38,10 @@
38
38
  "clean:dist": "tsx ../../scripts/clean-package-dist.ts"
39
39
  },
40
40
  "dependencies": {
41
- "@flighthq/importdiagnostics": "0.3.1-next.948.85d9f30",
42
- "@flighthq/tilemap": "0.3.1-next.948.85d9f30",
43
- "@flighthq/types": "0.3.1-next.948.85d9f30",
44
- "@flighthq/xml": "0.3.1-next.948.85d9f30"
41
+ "@flighthq/importdiagnostics": "0.3.1-next.970.9691e7b",
42
+ "@flighthq/tilemap": "0.3.1-next.970.9691e7b",
43
+ "@flighthq/types": "0.3.1-next.970.9691e7b",
44
+ "@flighthq/xml": "0.3.1-next.970.9691e7b"
45
45
  },
46
46
  "devDependencies": {
47
47
  "typescript": "^5.3.0"
@@ -25,6 +25,18 @@ const resolve: TiledTilesetResolver = (ref) => {
25
25
  };
26
26
 
27
27
  describe('buildTilemapLayersFromTiled', () => {
28
+ // A clean parse is two claims: the values are right AND THE PROJECTION IS NOT COMPLAINING. Every other
29
+ // test here checks the first. This checks the second — the one that catches a layer that projected into
30
+ // plausible-looking tile arrays while quietly reporting that it could not place some of them.
31
+ it('raises no diagnostic at all for a well-formed layer', () => {
32
+ const diagnostics: ImportDiagnostic[] = [];
33
+
34
+ buildTilemapLayersFromTiled(mapWithLayerData('1,2,1,2')!, 0, resolve, diagnostics);
35
+
36
+ const complaints = diagnostics.map((diagnostic) => diagnostic.kind);
37
+ expect(complaints, `a good Tiled layer made the projection complain: ${complaints.join(', ')}`).toEqual([]);
38
+ });
39
+
28
40
  it('splits a two-tileset layer into one TilemapData per tileset with local ids', () => {
29
41
  const map = mapWithLayerData('1,5,2147483649,6')!;
30
42
  const result = buildTilemapLayersFromTiled(map, 0, resolve)!;