How to use the @here/harp-test-utils.waitForEvent function in @here/harp-test-utils

To help you get started, we’ve selected a few @here/harp-test-utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github heremaps / harp.gl / test / rendering / GeoJsonDataRendering.ts View on Github external
const geoJsonDataSource = new OmvDataSource({
            decoder: new OmvTileDecoder(),
            dataProvider: new GeoJsonDataProvider(
                "geojson",
                typeof options.geoJson === "string"
                    ? new URL(options.geoJson, window.location.href)
                    : options.geoJson,
                { tiler: new GeoJsonTiler() }
            ),
            name: "geojson",
            styleSetName: "geojson"
        });

        mapView.addDataSource(geoJsonDataSource);

        await waitForEvent(mapView, MapViewEventNames.FrameComplete);

        await ibct.assertCanvasMatchesReference(canvas, options.testImageName);
    }

@here/harp-test-utils

Provides utilities for tests

Apache-2.0
Latest version published 2 years ago

Package Health Score

45 / 100
Full package analysis

Similar packages