GlobalVariables are reported as "not defined for test case" if running Test Suite collection (Linux)

Dear all,
faced a problem while trying to run Test Suite collection on Linux.

  1. I have N test-cases working fine
  2. They are combined into Test Suite working fine
  3. I’ve created a Test Suite collection having two instances of Test Suite (item#2) for 2 different browsers working fine locally (Windows)
  4. Project is published in Bitbucket Git repository
  5. I am trying to run Test Suite Collection on Linux using CI tool (Bamboo) and it leads to error in all test-cases

So, in the end, the “katalon …” instruction is executed, the project is accessed by the script, it tries to run each Suite and each test case inside one-be-one, but fails on each step requiring any Global Variable from the Profile, saying:

Message:
Test Cases/Signup FAILED because (of) Variable 'G_sender_password' is not defined for test case.

Which means in the end - even an instance of a browser is not started, because I have initial URL defined in Global Variable.

Could anyone assist please?

2 Likes

I’m having a similar issue - defined a URL as a Global variable and getting the following error trying to navigate to it:

Test Cases/LoginToNMA FAILED because (of) Variable ‘url’ is not defined for test case.

Please attach the screen shot of your “Test Suite collection” definition. I want to see which Profile is applied to each Test Suites.

The only profile I use is the default one.

Screenshot .png

Lily,

Please attach the screen shot of the Profile ‘default’. I want to see if ‘url’ is defined in it or not.

  1. I’ve created a Test Suite collection having two instances of Test
    Suite (item#2) for 2 different browsers working fine locally (Windows)

@Alex

Did you set the profile to use also into the Test Collection?

2018-10-03 14_31_05-Katalon Studio - api_v1 - [Location_ D__KataloonProj_api_v1].png

@10669-lily

a sample of your test script may help too. perhaps in the test case you are not initializing properly the ‘url’ variable?

It is defined as a ‘variable’ in the test case tab, or into the script?

see pic:

2018-10-03 14_41_43-Katalon Studio - api_v1 - [Location_ D__KataloonProj_api_v1].png

Ok, that was the problem.
I didn’t know that I should define it as a ‘variable’ in the test case itself as well.

Thank you, @11075-Ibus

lily said:

Ok, that was the problem.
I didn’t know that I should define it as a ‘variable’ in the test case itself as well.

Thank you, @11075-Ibus

yeah, it’s a common mistake. I’ve been hit by this too during first approach with this little katalon guy, coming from a postman world :slight_smile: