Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Testing Software Architecture

Testing Software Architecture

If anything, the Agile, Lean, and DevOps movements have proven that software architecture is not a “one man show”. Instead, in order to succeed, software design is a group effort that requires involvement from different stakeholders. In this session I’d like to talk about the testing aspect of software architecture and design.
We will see what exactly is this “important stuff”, that we use to call software architecture; what are its goals, and what differentiates a good architecture from a bad one? Next, we will discuss how to watch over a system’s architecture during the various stages of its development:
* The differences between under and over-engineering
* How to identify forming of a “big ball of mud” in early stages; and
* What are the symptoms of an exhausted architecture that is breaking under its own weight
Ultimately, I’ll demonstrate how such tests can be automated using static code analysis tools.

Vladik Khononov

October 17, 2019
Tweet

More Decks by Vladik Khononov

Other Decks in Programming

Transcript

  1. vladikk doit-intl.com Join at slido.com with #testcon2019 Design Patterns Libraries

    / Frameworks Infrastructural components Programming languages
  2. vladikk doit-intl.com Join at slido.com with #testcon2019 Adapting to changes

    in business Adapting to changes in technology Testing out assumptions Evolutionary architecture
  3. vladikk doit-intl.com Join at slido.com with #testcon2019 "Architecture is about

    the important stuff, whatever that is”
 - Ralph Johnson “Software architecture is those decisions which are
 both important and hard to change” 
 - Martin Fowler
  4. vladikk doit-intl.com Join at slido.com with #testcon2019 …but it’s hard!!!

    SOFTWARE SOLVES PROBLEMS GOOD DESIGN SUPPORTS THE BUSINESS
  5. vladikk doit-intl.com Join at slido.com with #testcon2019 THE GOAL OF

    SOFTWARE ARCHITECTURE IS TO MANAGE COMPLEXITY!
  6. vladikk doit-intl.com Join at slido.com with #testcon2019 1. Component level

    2. System level 3. Implementation level Complexity Management
  7. vladikk doit-intl.com Join at slido.com with #testcon2019 "System design …

    is inherently about boundaries - what’s in, what's out, what spans, what moves between, and about tradeoffs. It reshapes what is outside, just as it shapes what is inside.” - Ruth Malan
  8. vladikk doit-intl.com Join at slido.com with #testcon2019 FUNCTIONAL TESTING: UNIT,

    INTEGRATION, END-TO-END NON-FUNCTIONAL TESTING: PERFORMANCE, STRESS, SECURITY, USABILITY, ETC DESIGN TESTING: LOCAL AND GLOBAL COMPLEXITIES OF THE DESIGN
  9. vladikk doit-intl.com Join at slido.com with #testcon2019 Good Architecture Easy

    to navigate Easy to contribute Easy to change Delivers business goals
  10. vladikk doit-intl.com Join at slido.com with #testcon2019 Bad Architecture Hard

    to navigate Hard to contribute Hard to change Under/over engineered Big ball of mud
  11. vladikk doit-intl.com Join at slido.com with #testcon2019 "A Big Ball

    of Mud is a haphazardly structured, sprawling, sloppy, duct-tape-and-baling-wire, spaghetti-code jungle. These systems show unmistakable signs of unregulated growth, and repeated, expedient repair. Information is shared promiscuously among distant elements of the system, often to the point where nearly all the important information becomes global or duplicated.” - Joseph Yoder
  12. vladikk doit-intl.com Join at slido.com with #testcon2019 ARCHITECTURE = BOUNDARIES

    DESIGN GOOD ARCHITECTURE: GOOD BOUNDARIES BAD ARCHITECTURE: BAD BOUNDARIES
  13. vladikk doit-intl.com Join at slido.com with #testcon2019 So9ware Engineers Hard

    to add new functionality Hard to change existing functionality Impossible to unit test
  14. vladikk doit-intl.com Join at slido.com with #testcon2019 QA Engineers Defects

    caused by logic duplication Regression testing in-proportionally long
  15. vladikk doit-intl.com Join at slido.com with #testcon2019 Database Administrators Multiple

    sources of truth Inconsistent data that has to be fixed manually Lack of transactions due to design constraints
  16. vladikk doit-intl.com Join at slido.com with #testcon2019 OperaAons No DevOps

    culture Big releases Rare deployments Complex configurations for components
  17. vladikk doit-intl.com Join at slido.com with #testcon2019 OperaAons No DevOps

    culture Big releases Rare deployments Complex configurations for components So9ware Engineers Hard to add new functionality Hard to change existing functionality Impossible to unit test QA Engineers Defects caused by logic duplication Regression testing in-proportionally long Database Administrators Multiple sources of truth Inconsistent data that has to be fixed manually Lack of transactions due to design constraints BAD BOUNDARIES = EVERYBODY SUFFERS
  18. vladikk doit-intl.com Join at slido.com with #testcon2019 StaAc Code Analysis

    Analyze the codebase Query the code’s health Flexible health rules definitions Build pipeline integrations
  19. vladikk doit-intl.com Join at slido.com with #testcon2019 Software architecture manages

    complexity Local and global complexities Everyone suffers if module boundaries are ineffective Look for symptoms of bad boundaries. And react! Use static code analysis tools to control codebase evolution Look for chages in the organization structure and business strategies that affect software design