mapicgc-gl-js 1.0.2 → 1.0.3

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/README.md CHANGED
@@ -113,9 +113,43 @@ MapICGC GL JS integrates the following libraries:
113
113
 
114
114
  <br>
115
115
 
116
+
117
+ ## Tests
118
+
119
+
120
+ ## Tests
121
+
122
+ This project includes an automated test suite using [Vitest](https://vitest.dev/):
123
+
124
+ - **test/vitest/MapFunctions.test.js**: Covers all public methods of the `Map` class, including:
125
+ - getConfigStyles, getConfigWMSLayers, getConfigOrtoLayers, getConfigVectorLayers
126
+ - addControl, addLayer, addSource, addMarker, addAttributionControl
127
+ - setStyle, setSky, setEventedParent, setFeatureState, hasControl, _dealOrto3dStyle
128
+ - And many other public methods and behaviors
129
+
130
+ - **test/vitest/Config.test.js**: Tests configuration loading and structure (`ConfigICGC`):
131
+ - Remote and local config loading
132
+ - Fallback if the API call fails
133
+ - Validation of the `mapicgc-config.json` structure (default options, styles, layers, terrains, geocoder, logo, map3d, etc)
134
+
135
+ All these tests pass successfully with:
136
+
137
+ ```bash
138
+ npm run test
139
+ ```
140
+
141
+ or directly with Vitest:
142
+
143
+ ```bash
144
+ npx vitest run
145
+ ```
146
+
147
+ ---
116
148
  ## Developed by:
117
149
 
118
- <a href="https://www.icgc.cat/" target="_blank"><img src="https://eines.icgc.cat/recursos/logos/ICGC_color_norma.svg" alt="ICGC Logo" width="150"></img></a>
150
+
151
+
152
+ <a href="https://www.icgc.cat/" target="_blank"><img src="https://eines.icgc.cat/recursos/logos/ICGC_color_norma.svg" alt="ICGC Logo" width="150"></img></a>
119
153
 
120
154
 
121
155
  ## License
@@ -0,0 +1,13 @@
1
+ //#region node_modules/@watergis/maplibre-gl-export/dist/chunk-efA98nb6.js
2
+ var e = Object.create, t = Object.defineProperty, n = Object.getOwnPropertyDescriptor, r = Object.getOwnPropertyNames, i = Object.getPrototypeOf, a = Object.prototype.hasOwnProperty, o = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports), s = (e, i, o, s) => {
3
+ if (i && typeof i == "object" || typeof i == "function") for (var c = r(i), l = 0, u = c.length, d; l < u; l++) d = c[l], !a.call(e, d) && d !== o && t(e, d, {
4
+ get: ((e) => i[e]).bind(null, d),
5
+ enumerable: !(s = n(i, d)) || s.enumerable
6
+ });
7
+ return e;
8
+ }, c = (n, r, a) => (a = n == null ? {} : e(i(n)), s(r || !n || !n.__esModule ? t(a, "default", {
9
+ value: n,
10
+ enumerable: !0
11
+ }) : a, n));
12
+ //#endregion
13
+ export { o as n, c as t };