Model Based Testing – Shifting Right into the Real World (#PNSQC2021 Live Blog)
Wow, it's already the end of day one. That went fast!
We're now down to our last keynote for the day, which is Jonathon Wright talking about Model-Based Testing. Serious props to Jonathan as he is in Oxfordshire, UK, so he's already into tomorrow to talk to us today.
So we hear a lot about shift-left, meaning tet to the earliest possible moment to test. That must mean that shift right means that we can wait to the very last moment to test... well, no, not really ;).
It might make more sense to look at shift-left and shift-right not so much as when to test as opposed to what to test in what capacity. Shift-left means we are testing requirements, initial development, unit tests, integration tests, system test, and exploration to help us learn as much about the product as we can before the product goes out.
To be clear, that's the middle part of this shift metaphor. Shift-left is all about what we do before the product ships. Shift-right is everything related to what the product does after it is deployed. Testing is happening in earnest at this point, only the testers now are our customers as well as us monitoring and examining outcomes. Curious about what features are actually being used and by who? that's a shift-right process and relevant after the product ships. The point being, our testing efforts don't stop just because the product has gone out the door. In fact,a lot of interesting testing can only be done after it does.
Much of the process of looking at testing options can be broken down into a number of key steps, and each of those steps can be modeled or stubbed to help look at how interactions relate to one another. Using last year's example of COVID-19 tracing, there's an ability to use these model-based options to help us potentially set up transactions and communications so that we can look at what the possible options for each area might be. Using COVId-19 as the example (a contact tracing app) it looks at the details of what individuals do or expect to do and to see what happens at each node. what do we do if we determine we have been exposed? How can we determine that we have been using the contact tracing models? What happens if I test positive? What should I do? What does the app tell us I should do with a positive test? Who can I contact, who should I contact? Will that contact bubble out and through to others? Ultimately, how do we react to the data we receive under specific circumstances?
As a musician, I am used to using modeling software for instruments (bear with me, this will make sense, I promise). A number of applications go to great lengths to model various instruments and parameters that we can change. One of the interesting tools I use is an application called Moto Bass. It has the ability to make whatever bass I want to create, and in addition, it lets me move a number of the elements so that I can craft a sound, an attack, a playing method that might fool people into thinking it's playing a particular style of bass with a specific attack. It's 100% fake, as in no bass player is actually playing it but with practice, I can literally create a bass line that would be indistinguishable from a real bass player playing. That may sound powerful but really the true power is the modeling that is going on, and how much I can manipulate those modes. I can literally create something that adds a human approach such as varying plucking at different places on the string and creating movement in the playing. It's wild and defies logic, but it sounds remarkably convincing.
In many ways, this is specifically what I am doing as I model testing. I'm looking to see what odd or unusual data sets can be surfaced and see where and how they will be represented. I find that quite cool :).