ddubrava / angular-yandex-maps

🗺️ Yandex.Maps Angular components that implement the Yandex.Maps JavaScript API
https://ddubrava.github.io/angular8-yandex-maps/#/
MIT License
57 stars 7 forks source link

Improve coverage for YMapControl and YMapHint #252

Open ddubrava opened 1 month ago

ddubrava commented 1 month ago

These components are not fully tested because the logic within the HintContainer and ControlContainer components is too complicated to be easily tested.

ControlContainer is relatively straightforward since there isn't much logic. The only issue is that we need to properly mock ymaps3.YMapGroupEntity<any>, as it is currently a function that is extended, and the overrides don't work for it.

HintContainer is insanely hard. E.g., it is impossible to catch throw new Error from synchronous code. And there is a lot of complicated API that needs to be mocked