Goodbye Unit Testing: Introducing Codeless

Rishi Singh

June 25, 2024

I am excited to share a major milestone in software development with you. At Sapient.ai, we are introducing Sapient Codeless —a product designed to transform how we approach unit testing and to tackle one of the biggest challenges in software engineering.

Unit testing, as practiced today, is fundamentally broken. There is a reason why so many software teams neglect unit testing, let alone reach the “industry standard” 70% of coverage. Unit testing, a crucial aspect of ensuring code quality, often requires developers to write more test code than the actual functional code they’re testing. In some cases, two to ten times more code! Imagine that — how long should we accept this reality that test code is 5x larger than the actual code? This leads to increased code sprawl, burdensome maintenance, and inevitable slowdowns in development velocity. 

“Unit testing, as practiced today, is fundamentally broken.”

A Paradigm Shift in Testing

Today, I’m proud to introduce Sapient Codeless, a revolutionary approach that breaks free from these limitations. Built on the foundation of our existing proprietary AI models, it’s designed to eliminate the need for maintaining unit tests as code. Instead, we focus on the core principles of testing — inputs and outputs — abstracting the complexity of test maintenance entirely out of the developer's hands.

This is a new way of testing, at the unit level. The only thing we share in common with traditional unit testing is altitude, i.e. where and what we're testing. 

‘How’ the testing is done is the novel approach that we're introducing to the world for the first time, ever.

Imagine for a minute that unit testing is essentially considering a set of inputs (the method arguments) and generating logic to test against all possible output scenarios. Abstractly, if you can solve for the actual testing logic, you’re effectively only left with the inputs and outputs! This logical thought process is exactly what led us to invent Codeless Unit Testing

“The only thing we share in common with traditional unit testing is altitude, i.e. where and what we're testing. ‘How’ we're testing is the novel approach that we're introducing for the first time, ever.”

Codeless offers a no-code approach that provides a seamless and intuitive user experience. By simply selecting the methods to test, developers can have their unit tests automatically generated, with Sapient’s AI handling the underlying logic behind the scenes. This allows teams to ensure code stability without writing a single line of test code.

How It Works

Codeless abstracts the core fundamentals of unit testing to focus purely on testing various possible inputs to a method and their potential outputs. Our AI models automatically analyze the code and determine the possible inputs and outputs, generating the necessary tests behind the scenes. This means developers can focus on what matters most—ensuring code quality and delivering features at speed.

The Benefits:

  1. Effortless Test Generation: With Codeless, developers no longer need to write test code manually, freeing them from the burden of maintaining unit tests.
  2. Accelerated Velocity: By automating the generation and maintenance of unit tests, teams can move faster, delivering features without sacrificing test coverage.
  3. Enhanced Coverage: The intuitive UI allows developers to gain comprehensive test coverage effortlessly, which would otherwise be challenging to achieve with traditional methods.
  4. Adaptability to Code Changes: Changes in functional code often mean rewriting tests, but with Codeless, tests adapt automatically to code changes, saving significant time and effort.
  5. Reduced Technical Debt: By eliminating the need to maintain test code, teams can reduce technical debt and focus on building innovative solutions.

Transforming How We Test

Codeless Unit Testing is a paradigm shift in how we think about testing. Here are some scenarios where it can make a significant impact:

  • New Applications: For companies looking to bring new applications to market quickly, this solution offers the benefits of rapid development and code stability without sacrificing quality. Teams can ship features faster and with more confidence, knowing that the underlying tests are in place.
  • Legacy Applications: For legacy codebases with outdated tests and minimal coverage, Codeless provides a way to quickly gain coverage and update tests without needing to rewrite code. Organizations can move forward confidently, knowing their legacy applications are thoroughly tested without dedicating resources to rewrite tests.
  • Development Teams: For teams of all sizes, Codeless represents a new standard in software testing. It empowers developers to adopt a test-driven approach without being burdened by the effort traditionally associated with unit testing.
“Codeless Unit Testing is a paradigm shift in how we think about testing.”

A Journey Forward

Are we going against our flagship product? Yes, absolutely. And we're okay with that. Our first product taught us a fundamental principle: it's not so much about how you're generating the code; the issue is the code itself. AI generators, while useful, just add more code to the problem. This realization was a stepping stone towards the evolution of our new product. Are we still going to offer AI unit testing? Absolutely, because we have many happy users who may not be ready for codeless, and that's okay, too.

The development of this product reflects our vision of a future where testing is seamless and integrated into the development process, without the overhead of test code. This journey toward a code-free approach to testing marks a significant leap forward in software engineering. By focusing on inputs and outputs, Codeless streamlines the testing process, allowing developers to focus on what truly matters—building innovative features that propel their businesses forward.

Sapient.ai’s mission is to empower developers to deliver quality software without compromise. With Codeless Unit Testing, we're breaking down the barriers that have traditionally made unit testing a challenge. Our aim is to provide a solution that adapts to the needs of modern development while enabling teams to deliver at the pace required in today's fast-paced world.

Thank you for joining us on this journey. We are excited about the future of testing and how Codeless Unit Testing can help shape that future.