Every test automation needs investment to start with. With every new test, the overall execution time increases. Why write so many new tests if you do not have time to run them? What is the point of using Data-Driven Testing to multiply those numbers even more if you are already out of time? The most common solution is to add more manual testers, however, this means an increase in cost for testing. Is there a way to avoid that?
If you only know what you will be testing, how it will be done, and have broad technological knowledge? yes. But should this be a part of a project’s budget, if you can get a proper solution which solves all these problems for you? No. Let me guide you through some of the solutions AnkrPt provides to you.
Do you want to invest time and money into writing and maintaining your automated test technology, or do you want to invest into writing automated tests?
Today most web browser testing uses Selenium. Selenium is a well-known library that lets you interact with any page you can display in the browser. However, it cannot handle all problems that occur during page rendering. Such as?
One of the most randomly occurring issues is
StaleElementReferenceException. This happens when you have already retrieved a web element from the browser but the structure somehow changes and you can no longer interact with it. This can be caused by many behind-the-scenes mechanisms in Guidewire InsuranceSuite such as asynchronous Ajax processing, slow refreshes or unexpected issues. CenterTest handles these for you.
Result: lower failure rate due to Selenium complexities.
Value: eliminate time lost rerunning tests.
The clock is ticking…
Do you encounter situations when you need to wait for an element to appear or be enabled? Do you wait for the policy transaction status to change or a post on change action to finish processing? Do you wait for a page to finish loading before setting values? If yes, then you know how many lines of code you need for this. Every wait needs a different maximum timeout, polling time, or CSS selector. Using our Guidewire knowledge, we provide methods that efficiently wait for Centers’ elements. For example, methods that set the value as soon as the element becomes available or start the next step once the right page is loaded.
Result: no need for specialized wait code or hardcoded sleep
Value: check how many hardcoded sleeps you use and imagine every one of them gone which significantly shortens the overall test execution time.
Webdriver? Which version?
Every execution using Selenium needs web drivers to be available. Not everybody knows that they must be compatible with the local browser’s version. Some of the issues encountered during test execution are a result of this discrepancy. CenterTest provides a built-in web driver manager which always ensures you get a proper driver.
Result: no need to worry about web drivers.
Value: recover time lost analyzing web driver version incompatibilities.
Manual actions? Forget it.
Many automated frameworks in the market handle only web-browser interactions. When you need them to achieve more, it is a problem. Document validation? They require manual testers for verification. Call external API? Give someone SoapUI or Postman, and they can do it. Need to run some batch jobs or make a payment in Guidewire BillingCenter? Again it can be achieved with manual process and/or another test. CenterTest gives you the ability to not only run simple flows in, for example, PolicyCenter but much more. You can upload, download and validate documents. You can run multiple browsers with multiple sessions to multiple Centers within one test and interact between them. You can call any external API like aggregators. You can even automate full end-to-end tests without manual intervention!
Result: no manual actions needed, automate more steps of your tests.
Value: no delays, no human intervention needed.
Start, stop, restart
A test can fail for many reasons, some unexpected, others by design. What are designed test failures within Guidewire applications? These are failures such as waiting for a document to generate, batch jobs to complete, or even time travel to occur. One way to handle failures is to simply rerun the test from the beginning. This is common and may sometimes work, many times won’t, or may even create new problems. A better way is to restart the test from its point of failure after resolving the reason for failure. This is called Restartability and is critical for complex tests. How does it work?
CenterTest Restartability works because tests have context to themselves. They know what they did, what to skip, what to check, and when to continue. All without you having to do anything other than restarting.
A simple example within Guidewire PolicyCenter is renewals: create an account and a policy then wait for a specific date. Once time travel occurs, restart skips past the account/policy creation and continues with the renewal process. All handled with one Restartable test.
Can this manage multiple tests? A test suite? Yes. Every test independently waits for its specific conditions to be met. So if your test suite has numerous tests waiting for a specific date, time travelling to that date will result in all related tests continuing upon restart.
Result: one test for a complex conditions, no manual action needed.
Value: no delay between test steps, faster test execution.
Divide and rule
As you continually add tests, you will hit time limits for the overall execution. What can we do? Run in parallel. How? Use CenterTest. CenterTest provides built-in mechanisms to run tests using Selenium Grid on your local server or using remote, cloud or dedicated servers. It doesn’t matter, you simple point to your Grid. If you run local, AnkrPt manages starting and stopping servers as needed.
During test execution, queues, threads and Selenium nodes are all handled by CenterTest. The only limit is application server constraints. You can even run stress tests by simply increasing concurrent tests, saving you the time you would spend implementing additional tools.
Result: ability to run multi-threaded tests
Value: more testing in less time, saving money.
Who is in control?
Most automated testing solutions in the market need you to give them access to your application. Not CenterTest, it is deployed on your premises and it is you who decide how to run it. A simple solution with scripts running the JAR file? Done. AWS or Google Cloud environment? No problem. Containers like Kubernetes or Docker? No worries. CI using Jenkins? Already there. You can also use AnkrPt WebServices or AnkrPt Dashboard to run your tests. The choice is yours, don’t waste time on unnecessary configurations.
Result: you choose how you run tests
Value: the time you would spend on configuring VPN and other connection parameters
Senior Software Architect
Watch or read our other posts at Kimputing Blogs. You’ll find everything from Automated testing to CenterTest, Guidewire knowledge to general interest. We’re trying to help share our knowledge from decades of experience.