cenfun / monocart-reporter-examples

Monocart Reporter Test Examples
7 stars 0 forks source link

How can you collect comments data? #4

Closed vittorioc98 closed 10 months ago

vittorioc98 commented 10 months ago

Hello!

May i ask how do you collect Comments data from tests?

Here: https://github.com/cenfun/monocart-reporter-test/blob/main/integrations/xray/xray.js, at line 57, you call item.xray. I suppose that this will grab the JSDoc @xray value. How can i achieve this in my custom reporter? I'd like to grab those values and use it to build a custom reporter..

Thanks a lot, Vittorio.

cenfun commented 10 months ago

it required visitor options, see config: https://github.com/cenfun/monocart-reporter-test/blob/main/integrations/xray/playwright.config.js#L20-L36

vittorioc98 commented 10 months ago

Does it only work with monocart reporter? Because I have my custom one.

cenfun commented 10 months ago

yes, the comments data was collected by monocart reporter

vittorioc98 commented 10 months ago

Oh ok, unlucky. Thank you for your time.