Your Privacy

This site uses cookies to enhance your browsing experience and deliver personalized content. By continuing to use this site, you consent to our use of cookies.
COOKIE POLICY

Software Engineering to Requirements with SOLID and Automated Testing

Software Engineering to Requirements with SOLID and Automated Testing
Back to insights

When designing software applications, it is imperative that the application supports the requirements. The ability to align requirements to implementation for complex systems is not a skill that is taught in school. No single developer can have a holistic understanding of a complex system. The parts of the complex system that are not understood are ripe for requirements gaps and bugs.

SOLID Principles

The SOLID principles are simple to understand, yet surprisingly difficult to follow. The principles strive for focused, maintainable and testable objects. In contrast, code encountered in the wild frequently reveals bloated God classes. Addressing requirements through God classes is tempting because it allows the author to skip the design phase of the Software Development Life Cycle and jump right to implementation. A downside to this approach is that engineers new to the project will need to read and understand every single line of the God class before making changes. Additive changes to the God class will increase its complexity. Over time, the class will become extremely difficult to understand and maintain and will start yielding requirements gaps and bugs. If the same greenhorn engineers were presented with a codebase designed with SOLID principles in mind, they should quickly identify their desired point of change due to the single responsibility principle and have a less difficult time understanding the code.

This sample Spring Boot and Mockito-based project for a cake store was developed following SOLID principles. Without knowing how to program, one could likely locate the section of the code containing the logic for validating orders at the cake store. Since the order validation logic is co-located, this class can be linked to its corresponding story requirement in a project tracking tool like JIRA. The corresponding automated tests can be linked to the story requirement as well, ensuring basic test coverage.

Automated Testing

Software applications designed following the SOLID principles are easily testable. Developers can verify code by creating automated unit and integration tests for the requirements. Since these automated tests generally take seconds to execute, functionality can be verified on demand. Tech-savvy stakeholders are pleased to see successful automated unit and integration test results, as they can help to gauge real-time development progress. It does not take too much effort to teach an interested stakeholder how to run unit tests.

Having requirements traceability and basic test coverage is meaningful to all parties on a software project because they aid in verifying the application. Software designed with SOLID in mind makes this traceability task easier to perform. Software designed with God classes will yield untestable and complex code that will hinder requirements traceability. Consider pursuing SOLID design for your next software project.

About Cody Halbleib

Cody Halbleib is a Senior Consultant on the Software team. His family is his partner, Jamie, and his Border Collie mix, Walter.

Digging In

  • Digital Products

    The Growing Importance of Digital Accessibility

    Embracing Digital Accessibility: A Moral and Business Imperative In today’s digital landscape, accessibility has become crucial for businesses and organizations. With increasing awareness and legal requirements, ensuring that digital products are accessible to all users, including those with disabilities, is not just a compliance issue but a moral imperative. At UDig, we champion ADA compliance […]

  • Digital Products

    Unlocking Business Potential: The Power of Custom Application Development

    Like any savvy business leader, you’re likely always on the lookout for tools to give your company a competitive edge. And in doing so, you’ve undoubtedly considered investing in custom application development. But the question is, how do you ensure that such a major investment in a custom web application development provides a strong return on […]

  • Digital Products

    Mastering Legacy Application Modernization: Strategies for Success

    The ironic truth of the business world is that change is the only constant. But this means that failing to keep pace with the competition and its technologies will only end with you falling behind. That’s where legacy application modernization enters the fold. When you modernize legacy applications, your team gains access to new features […]

  • Digital Products

    CTO Confessions Podcast

    In this episode of CTO Confessions, Rob Phillips, the Vice President of Software Engineering at UDig, digs into his journey from a passionate technologist in his youth to a seasoned leader in the tech industry. He shares valuable lessons on transitioning to senior leadership, the importance of understanding and articulating company problems, and the art of empowering teams for high performance.

  • Digital Products

    Navigating the Challenges of On Premise to Cloud Migration

    In today’s rapidly evolving technological landscape, the shift from on premise solutions to cloud-based infrastructure has become a pivotal transformation for organizations seeking to modernize their IT operations. This transition holds the promise of increased agility, cost savings, and enhanced scalability. However, it is not without its set of formidable challenges that organizations must navigate. […]

  • Digital Products

    The Power of Transferrable Skills in Tech Projects

    Every project has its own unique elements that require flexibility to be effective and achieve success. This often requires picking up new pieces of a tech stack, learning a new programming language, or a new project methodology. Fortunately, there are also many transferrable skills that carry over from one project to the next. In my […]