Skip to content

Implement Node.js test suite with jest#23

Merged
rudokemper merged 2 commits into
mainfrom
add-jest-for-testing
Feb 2, 2024
Merged

Implement Node.js test suite with jest#23
rudokemper merged 2 commits into
mainfrom
add-jest-for-testing

Conversation

@rudokemper
Copy link
Copy Markdown
Member

Goal

Implement jest to add a basic test suite for Node.js.

What I changed

  • Implement jest and babel (to transpile ES6 syntax for jest).
  • Set up a testing environment in test.js (with a few workarounds, like mocking p-limit which apparently does not play well with jest)
  • Added one e2e integration test to generate an MBTiles file from a local, empty style. (Not the best example as of yet, more to come)
  • Added a few unit tests focused on testing valid and invalid API keys for Mapbox and Planet

What I'm not doing here

I only added a few basic tests, so this is by no means a comprehensive suite. More tests to come in the future.

@rudokemper rudokemper merged commit a882c23 into main Feb 2, 2024
@rudokemper rudokemper deleted the add-jest-for-testing branch February 2, 2024 00:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant