contentful / field-editors

React components and extensions for building Contentful entry editor
https://contentful-field-editors.netlify.app/
MIT License
150 stars 114 forks source link

test: pass google maps key to LocationEditor component tests #1564

Closed SofiaMargariti closed 6 months ago

SofiaMargariti commented 6 months ago

LocationEditor component tests keep failing due to googleMapsKey not being set properly. These tests were recently migrated to component tests. Before they were ran on top of storybook stories which were passing the key correctly. This migration is most likely related to these failures, but I am still not sure why they passed here

z0al commented 6 months ago

Thanks for taking a look @SofiaMargariti , but we shouldn't really need a key here, accessing GMaps directly would cause flakyness again which is why it was mocked. However, it seems after this PR the mocks are being applied a bit too late when you compare the e2e version vs component.

Update: Nevermind, we are still mocking the API but the widget itself needs the key