Request to support Playwright Test and TypeScript #1623
Replies: 9 comments 24 replies
-
hi @JulieMatic 👋 Thanks so much for all the details, it's very helpful for our understanding of where the gaps are with the current Playwright support in Artillery. We absolutely want to support both Playwright Test and TypeScript. We're still figuring out what that's going to look like exactly. |
Beta Was this translation helpful? Give feedback.
-
Following this topic. I'm in the same situation. I want to reuse my existing POM made with TS + Playwright. Is there any update on this? |
Beta Was this translation helpful? Give feedback.
-
Does anyone have any tips for compiling TS tests to JS for Artillery? I tried using |
Beta Was this translation helpful? Give feedback.
-
I feel a bit disappointed. Artillery says you can use playwright, and that you can reuse your smoke tests as load tests. But if you've written your Playwright tests like Playwright recommends, using features of Playwright Test, you can't actually reuse your smoke tests as load tests and Artillery doesn't support Playwright. Maybe this should be added to Artillery's limitations section of the Playwright engine. |
Beta Was this translation helpful? Give feedback.
-
Initial TypeScript support was merged in #2360. It hasn't been released in a stable release of Artillery yet but is available in the canary release for anyone who wants to try it - |
Beta Was this translation helpful? Give feedback.
-
One thing that seems critical to me and has not yet been mentionned here : |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
Hey folks 👋 The new Artillery release (v2.0.6) contains improvements to the Typescript support. You should now be able to use Some documentation:
cc @dyllandry , @HugoImaios , @philwolstenholme , @ArCiGo , @JulieMatic |
Beta Was this translation helpful? Give feedback.
-
Might be off topic here, but do you have a pageObject example? Because in playwright we have a fixture.ts file which declares all the pageObject pages which extends playwright base pages... Or do we need to go to a more simpler version, of having pageObject.ts file and importing it into our test.ts? |
Beta Was this translation helpful? Give feedback.
-
My team is implementing all of our functional UI tests with Playwright Test written in TypeScript. We also currently have a very small subset of these tests which we would like to use for load testing via Artillery. Are there any future plans to support Playwright Test or TypeScript when running tests via Artillery?
Currently, the Playwright Test repository for our functional tests takes advantage of some of the very useful features that Playwright Test has beyond the core Playwright library. For example, we use:
beforeEach()
/beforeAll()
/afterEach()
/afterAll()
methods to handle setup and cleanup in a givenspec.ts
filetest.describe()
andtest()
methods to organize tests in a givenspec.ts
fileexpect()
method for assertionsspec.ts
filesOur current workaround for the lack of Playwright Test support is to store 2 copies of any test that needs to be performed as both a functional UI test and a load test and stripping out any Playwright Test features before compiling the test to JavaScript via a build script. I've seen on other posts that a suggested workaround is to create a function that both the Artillery and Playwright Test tests can call, but this isn't ideal for my team for a few reasons:
expect()
methodBeta Was this translation helpful? Give feedback.
All reactions