The text object not found


I have a site with a button that allows to change the language of the site (switch EN / FR)

When I click on the button, the “text” attribute changes (en or fr).

I want Katalon to check that the text of the button is either in FR.

my code :

attribute = WebUI.getAttribute(findTestObject(‘SwitchLanguage/button_en’), ‘text’)

If attribute = (‘EN’){

My code for website EN

} else{

My code for website FR


i have a error…

Do you have an idea?

Thank you :slight_smile:

Capture d’écran 2018-01-31 à 18.09.52.png

hello team,
idea ?


I have the same issue. Can anyone help us?

Can I know the web that you used for testing?
The chances might be that the object is not found in the page. Have you tried using the object spy to look for the object?