js-waku
js-waku copied to clipboard
Add interoperability tests with nwaku to browser suite
This is a change request/
Problem
Interoperability tests are only executed in NodeJS because we setup the nwaku node as part of the test. This is not possible in the browser as the browser cannot start a process etc,
This means some bugs: https://github.com/status-im/js-waku/issues/886 can only be found once we manually test js-waku in an example, against a nwaku fleet.
Proposed Solutions
Do some interop test in the browser.
The current NodeJS strategy is unlikely to work (start nwaku node in beforeEach
hooks) so we may need to use a different approach:
- Start a local fleet of nwaku nodes first
- Set node connection details in a global variable
- Use these nodes to run the test, possible using dynamic content topic to avoid test clashing
This may actually result in the test suite running faster as it means nwaku nodes are re-used and started in parallel.
Investigating execute some beforeEach
like hook with karma framework might make sense too but should be time boxed.