TestProject Forum

TestProject Platform => TestProject SDK => Topic started by: jaydeep.paradise on August 03, 2018, 09:47:08 am

Title: How to organize WebTest code and how to debug it?
Post by: jaydeep.paradise on August 03, 2018, 09:47:08 am
If I will create any methods at outside of the
"public ExecutionResult execute(WebTestHelper helper) throws FailureException()" method.

then will it be working fine in my debugger module?
Will my jar file upload on testproject?
After upload on test project that methods will be working?
What's the purpose of above mentioned method?

Note: I have read the docs but still I have above query.
Title: Re: Clarify the below confusion
Post by: Marat Strelets on August 03, 2018, 12:34:37 pm
Hello,

In order to create an action or a test, one of the TestProject SDK interfaces must be implemented.

All of the interfaces require to implement the  execute method that will be invoked by the TestProject Agent.

You can create as many methods as you need in your Test or Action class, but execute method will serve as an entry point.
Title: Re: Clarify the below confusion
Post by: jaydeep.paradise on August 03, 2018, 14:12:04 pm
ok understand.

one more question:

1) If I will write my all the logic in Execute method then it will be working fine?

2) With Testproject SDK I need to use some Selenium method like "WebElement". So is it fine?
Title: Re: Clarify the below confusion
Post by: Marat Strelets on August 03, 2018, 15:15:02 pm
Yes, it's fine to code all the logic in this method, as long as the code is not too long and remains maintainable.

TestProject SDK contains Selenium and Appium client libraries inside, there is no need to reference them explicitly.
You can definitely use any Selenium API and classes in your code.