Load Testing Single Page App (react) #302
-
How do you go about testing SPA'S using xlt? How do you go about navigating to log in "page" or to any other "page"? I've downloaded xlt 6.2.5 and when I try to find page elements using selectors, the elements aren't found. Do I need to enable anything in the properties files? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
I assume you are talking about performance testing? PWA is a difficult beast because it depends heavily on the JavaScript stack as well as on the rendering of components. The current underlying version of the library HtmlUnit does not fully support Chrome-like JS and rendering. Most load test tools don't support rendering at all (but XLT has an option, see later), and therefore you have to load test the API behind the PWA. Load and performance testing in this case is not about the rendering performance, rather the backend performance. HtmlUnit is working on improving the support, but likely will never behave like a real browser. Hence, you can go different routes:
|
Beta Was this translation helpful? Give feedback.
-
As mentioned before, React-based sites are heavily in JS and custom rendering, hence when you don't have a full blow real browser, you don't get what you want. The load test strategies are:
|
Beta Was this translation helpful? Give feedback.
As mentioned before, React-based sites are heavily in JS and custom rendering, hence when you don't have a full blow real browser, you don't get what you want. The load test strategies are: