Closed Palash9088 closed 1 year ago
@Palash9088 I did not understand the issue. Could you please be more specific? Provide steps that you do, what you expect and what happens instead. From what I see, your provided a custom expect
message and it was shown in the report, which looks good to me.
I mean to say that in testng when we use assertion -> Assert.assertEquals("playwright", "playwright", "Title not matched"); Assert.Method( actual, expected, String) so in the string we give some text & it comes when that particular assertion get failed. In playwright the assertion string text becomes the test title even if it get passed or failed it shows the same message
by the above image I think you would understand & message should be displayed when that particular expect get failed it should not become the title of the expect
@dgozman It get closed mistakenly.
@Palash9088 Thank you for the clarification. What would you like to see in the report when assertion has passed, instead of the custom message?
simply what assertion we have used should be displayed in that like in the above image, & when it get failed then the custom message should be appear. like in this image, that custom message should visible when test get failed, in image it is passed but expected outcome should be "custom message should visible when test get failed".
I think it works correctly. You expect that "vwo keyboard isn't visible" and it's true so you see a tick. It's logic. When you are looking at the report, it's easier to verify business logic. In the first example, it's just changed to "The count is greater than zero"
@kasperkow thankyou for clarification.
I have raised one bug kindly look into this as well https://github.com/microsoft/playwright/issues/23282
Closing this one.
Let us know what functionality you'd like to see in Playwright and what your use case is. When we use any assertion in playwright so the message we give should come up when the test case get failed like it happen in testng but playwright thinks that it is name of the assertion & it shows that as well in the report doesn't matter it gets passed or failed. Do you think others might benefit from this as well? yes, people are moving from selenium playwright so it should be similar to the things they are using so people will feel more confident to use playwright.