realm-js icon indicating copy to clipboard operation
realm-js copied to clipboard

Improve running tests when server is missing

Open kraenhansen opened this issue 1 year ago • 0 comments

What, How & Why?

I want to improve the default experience of running our tests. Unfortunately, contributors to the project isn't allowed to pull the docker image and run the test server, but that shouldn't keep them from running tests at all. In its current form, its a subtly documented feature of the test runner that you can run with missingServer context, but I want to make this more obvious and improve the default experience (when the server is missing).

If the environment does not explicitly provide a baseUrl nor set missingServer=false the tests using importAppBefore will skip if the app import fails due to a connection refusal. If this happens, a warning will be printed after all tests has ran:

Screenshot 2024-02-19 at 11 38 53

☑️ ToDos

  • [ ] 📝 Changelog entry
  • [ ] 📝 Compatibility label is updated or copied from previous entry
  • [ ] 📝 Update COMPATIBILITY.md
  • [ ] 🚦 Tests
  • [ ] 📦 Updated internal package version in consuming package.jsons (if updating internal packages)
  • [ ] 📱 Check the React Native/other sample apps work if necessary
  • [ ] 💥 Breaking label has been applied or is not necessary

kraenhansen avatar Feb 19 '24 10:02 kraenhansen