in

Is there a configuration to control the rate of calls between a VS C# Specflow Test Case and an Appium Server


I am writing some c# automation for an Android App using Selenium and Appium. While I am getting the functionality I want, the execution is quite slow. This appears to be caused by something controlling the rate of requests being sent to the Appium Server from the VS C# code. For example, this is a line of code that checks if a button is displayed and enabled

Assert.That(Button.Displayed && Button.Enabled, $”Button {p0} Not Displayed and Enabled”);

From the Appium Log file, this code results in 2 separate calls to the Appium Server, which are resolved in 15 and 19 ms each, but for some reason these calls (and the one following which clicks the button), appear to reach the Appium server 2 seconds apart. This leads to 34 ms of actual work but an elapsed time of 4,132 ms, very ineffective.

2021-12-30 16:07:52:970 – [HTTP] –> GET /wd/hub/…/00000000-0000-0160-ffff-ffff000000ac/displayed
2021-12-30 16:07:52:970 – [HTTP] {}

2021-12-30 16:07:52:985 – [HTTP] <– GET /wd/hub/…/00000000-0000-0160-ffff-ffff000000ac/displayed 200 15 ms – 14

2021-12-30 16:07:52:991 – [HTTP]

2021-12-30 16:07:55:042 – [HTTP] –> GET /wd/hub/…/00000000-0000-0160-ffff-ffff000000ac/enabled

2021-12-30 16:07:55:042 – [HTTP] {}

2021-12-30 16:07:55:061 – [HTTP] <– GET /wd/hub/…/00000000-0000-0160-ffff-ffff000000ac/enabled 200 19 ms – 14

2021-12-30 16:07:55:061 – [HTTP]

2021-12-30 16:07:57:102 – [HTTP] –> POST /wd/hub/…/00000000-0000-0160-ffff-ffff000000ac/click

Maybe the delay is the result of whatever causes the empty row to be written to the log file i.e. “2021-12-30 16:07:55:061 – [HTTP]”, but I have no idea what that is.



Source: https://stackoverflow.com/questions/70536131/is-there-a-configuration-to-control-the-rate-of-calls-between-a-vs-c-sharp-specf

Instagram Clone developed with Flutter & Firebase

HashiCorp Boundary 0.7 and Boundary Desktop 1.4 Released with Dynamic Host Catalogs