The mabl blog: Testing in DevOps

Introducing Database Connectivity: Validating Data with AI and Low-code

Written by Chris Hutchens | Aug 29, 2024 6:57:07 PM

Teams often struggle to efficiently connect to databases while testing their web and mobile apps. These challenges can stem from needing to use specialized technical skills, introducing complex scripting, and working with disjointed workflows, all of which can significantly hinder the efficiency and effectiveness of your testing efforts.

This is where mabl comes in. As a platform that empowers software teams with AI and automation, mabl focuses on democratizing testing to improve collaboration and efficiency, ultimately leading to the delivery of higher quality releases. With the introduction of mabl's new Database Connectivity feature, teams can now seamlessly integrate database validation into their testing workflows, regardless of their technical expertise.

The Importance of Database Connectivity

Direct database connectivity during testing is crucial in ensuring accuracy and efficiency. When teams have direct access to their data, the range of tests they can run opens up significantly. Being able to verify that the data shown in the interface matches the information store in the DB is made much easier. Complex test scenarios can be built more efficiently when test data can be populated directly in the database. And tests become cleaner and more maintainable because the management of test data setup and teardown is that much more efficient.

While direct database connectivity may not be the right format for all teams, it's crucial to recognize its value in specific scenarios. For instance, some teams may not have readily available APIs to interact with their databases, which means direct connectivity is the only option. In other cases, teams might be working with dedicated test databases where connecting directly is perfectly acceptable and even encouraged.

The Challenges of Database Testing

Traditional testing solutions often require in-depth knowledge of SQL and database structures, not to mention the intricate setup processes and the technical knowledge required to write effective queries. 

These complexities, along with the reliance on specialized skills, serve to limit the number of team members who can contribute to the testing process, slowing it down and creating bottlenecks for the entire team.

Introducing mabl's DB Connectivity

mabl's Database Connectivity is now available to all users, enabling teams to easily connect to, query, and validate data within their databases directly from their mabl web and mobile tests. Staying true to its roots, mabl has delivered the easiest-to-use solution among test automation platforms, making database interactions accessible to testers of all skill levels. The new solution simplifies the process of connecting to multiple database types, provides AI-assistance to generate queries, and streamlines executing queries, building assertions, and saving variables in the same fast, low-code platform mabl’s users know and love.

Key Features of mabl’s DB Testing

Connect and Query

With mabl, users can seamlessly connect to their databases–whether it's MySQL, Microsoft SQL Server, PostgreSQL, or MariaDB (with MongoDB and Oracle support coming soon)–ensuring comprehensive testing coverage across a variety of environments. Once connected, they can execute queries to retrieve and validate data directly within their mabl tests.

Easily connect mabl tests to MySQL, Microsoft SQL Server, PostgreSQL, and MariaDB (with MongoDB and Oracle support coming soon)

Build Assertions and save variables

With mabl's intuitive interface, it’s easy to create assertions that ensure data integrity and save query results as reusable variables. This makes complex test scenarios easy to manage and maintain, and allows for seamless integration of database validation into the broader testing workflow. Traditional testing solutions make database-sourced assertions and variable saving a cumbersome, time-consuming ordeal. mabl flips the script, empowering you to complete these actions in mere seconds.

Create variables from database queries, then use them just like any other variable in the mabl Trainer.

AI-Powered Query Generation

mabl's AI can assist users in generating queries, further lowering the barrier to entry for database testing. The AI leverages knowledge of the database schema and data structure, making it easy to generate fast and accurate queries based on natural language input. This feature empowers testers with varying levels of SQL expertise to make meaningful contributions to database testing.

Easily generate DB queries using mabl's AI assistant

comprehensive testing

mabl's DB Connectivity enables a wide range of testing scenarios. Teams can verify data consistency between their application and the database, populate test data for complex scenarios, and efficiently set up and tear down test data, ensuring clean and maintainable tests.

Data-Driven Testing

Data-driven testing allows users to save data into variables and leverage it as test input. This empowers testers to create dynamic and flexible tests that can adapt to various data scenarios, increasing coverage and efficiency.

Real-World Impact: Glytec's Success with mabl's Database Connectivity

"We found that database connectivity integrated seamlessly with end-to-end mabl testing," says Jonathan Kuehling, Test Automation Architect at Glytec. "We’re able to leverage this feature to have mabl synthesize traffic on our UI, then confirm tables were updated correctly on our SQL server. Thorough database testing is critical to ensuring our medical apps in hospitals are safe and reliable for doctors to use." 

This streamlined approach is replacing Glytec's previous reliance on complex and time-consuming Selenium Cucumber tests. "Since the database queries are embedded in the browser tests which the mabl AI continuously updates, a higher quality test can be achieved with lower tech debt and maintenance efforts!"

With mabl's Database Connectivity, Glytec will significantly reduce the lead time between issue detection and resolution. "Easier database testing means more QAs involved, and a reduced amount of time spent investigating issues, because mabl's AI did a considerable amount of the work for us!"

(NOTE: Glytec does not use live customer data for mabl testing, nor is it shared, stored, archived, or retained by their automated tests. Glytec's automated testing on mabl is fully compliant with HIPAA and patient privacy regulations.)

Conclusion

mabl's DB Connectivity is a game-changer for integrating Databases into your testing. Its low-code nature, AI assistance, and ease of use enable comprehensive database validation, regardless of technical expertise.

This new feature can be used across web and mobile testing, providing a unified solution for validating data integrity across the entire application stack. By seamlessly integrating database interactions into your testing workflows, mabl empowers your team to deliver higher-quality software with greater confidence.

We encourage you to try out the new Database Connectivity feature and experience the benefits firsthand. Sign up for a free 14-day trial and see how mabl can revolutionize your database testing efforts.