Skip to main content
Answer

Acumatica Test SDK - No Such element Exception

  • June 3, 2021
  • 1 reply
  • 194 views

Hi,

I’m having trouble with the acumatica’s automated testing wherein I wasn’t able to make the test pass every time I’m passing a value to the subaccounts. I’m getting this error

NoSuchElementException: Could not find a web element by the locator: css=#_ctl00_phG_tab_t0_PXGrid1_lv0_es div.buttonsCont > div

I already re-generated the wrapper file.

Tried using .Type

screen.VariableRateDetail.Row.ARSubAccountID.Type(detRow["ARSub"].ToString());

Tried using .Select

screen.VariableRateDetail.Row.ARSubAccountID.Select(detRow["ARSub"].ToString());

Tried overriding the Locator

screen.VariableRateDetail.Row.ARSubAccountID.Locator = screen.VariableRateDetail.Row.ARSubAccountID.ClearLocator;

Unfortunately, the error still persists. I have no clue on what causes the error.

I hope you can help me. Thank you.

-------------------------
Additional Information: The lookup mode for the Subaccount Segmented key is currently By Segment: All Avail. Segment Values.

Best answer by Naveen Boga

Hi @igalm15  Recently, we have worked on the TEST SDK automation testing for one of our products and we have faced this issue. Please find the details below for root cause and fix we have done for this issue.

Root Cause: This issue is caused by Test SDK and executing very faster, due to this when form elements are loading slow at that time we will get this issue.

Fix: we have used Thread.Sleep(2000); We are moving that thread to sleep for 2 seconds, by that time form elements will loading and executed with out any issues.

Hope this helps!

1 reply

Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • Answer
  • November 28, 2021

Hi @igalm15  Recently, we have worked on the TEST SDK automation testing for one of our products and we have faced this issue. Please find the details below for root cause and fix we have done for this issue.

Root Cause: This issue is caused by Test SDK and executing very faster, due to this when form elements are loading slow at that time we will get this issue.

Fix: we have used Thread.Sleep(2000); We are moving that thread to sleep for 2 seconds, by that time form elements will loading and executed with out any issues.

Hope this helps!