itwinjs-core icon indicating copy to clipboard operation
itwinjs-core copied to clipboard

Aidantran/no render app fix

Open AidanTran opened this issue 2 years ago • 6 comments

Created a test suite under full-stack-tests that tests the ability to establish an iModelConnection in Node outside of Certa. Emulates the structure and env file of ecschema-rpc-interface.

We still have to define fetch, Request, and xmlhttprequest globally. Fetch and Request are required by WebAppRpcRequest: https://github.com/iTwin/itwinjs-core/blob/86dad171da1e948fae45930586ecfe8824efce91/core/common/src/rpc/web/WebAppRpcRequest.ts#L258-L266 , and xmlhttprequest is required by i18next. (It could be possible in the future for i18next to rely on Fetch once this pr is merged: https://github.com/iTwin/itwinjs-core/pull/4052)

AidanTran avatar Aug 09 '22 15:08 AidanTran

Fixes https://github.com/iTwin/itwinjs-backlog/issues/326

pmconne avatar Aug 09 '22 15:08 pmconne

@pmconne I've added it as an integration step and it's passing, is that what you had in mind for the requested change?

AidanTran avatar Aug 12 '22 18:08 AidanTran

@aruniverse what is the difference between NoRenderApp and MockRender.App ? Is there one that should be used rather than the other or are they unrelated/doing different things ?

raplemie avatar Oct 06 '22 13:10 raplemie

what is the difference between NoRenderApp and MockRender.App

MockRender.App is for tests.

pmconne avatar Oct 06 '22 13:10 pmconne

what is the difference between NoRenderApp and MockRender.App

MockRender.App is for tests.

I thought so was NoRenderApp, so I guess this is unrelated.

raplemie avatar Oct 06 '22 13:10 raplemie

I thought so was NoRenderApp, so I guess this is unrelated

MockRender.App lets the test hook into and respond to calls into RenderSystem APIs. NoRenderApp simply avoids attempting to initialize WebGL and implements all RenderSystem APIs as no-ops.

pmconne avatar Oct 06 '22 13:10 pmconne

This pull request is now in conflicts. Could you fix it @AidanTran? 🙏 To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

mergify[bot] avatar Feb 24 '23 16:02 mergify[bot]