In order to understand what application testing looks like, we need to learn the concepts from which testing is derived.
Imagine a situation in which you are talking to a powerful AI. It's the year 2137, and all you have to do is ask a good question.... Exactly, but what does good mean?
In my opinion, it's a question that is short and specific. The kind you are currently asking in the GPT chat room. After all, by asking an overly complicated question before you get an answer, you have to ask more questions. It is much easier to ask one.
Of course, some problems are too complicated to be solved by a single question, so the problem should be broken down into smaller parts and to each of them ask a simple question - the
divide and conquermethodology.
That's what software testing is. You should divide the problem if it is complicated into
nparts, then ask specific questions and find answers to them.
People have been looking for answers forever. It's the same with testing. You look for answers to the questions you ask. Is the table flat? Is the earth flat? What will be the answers to these questions?
Of course, the table is flat, and the earth is not. However, if you go into the details, the table is not "perfectly flat" and the earth is not "perfectly round".
Here you can see the erroneously asked question. So the answer was also convoluted. Instead of hearing
noin the answer itself we had to resolve the doubts of the question...
As you can see the answers are dependent on the questions, not vice versa so before you start looking for them make sure that the question is the right one.
Divide and conquer
Let's suppose you work in a restaurant and teach a colleague to make pizza. How do you determine that your friend is making pizza the right way. The obvious thing is that you need to ask some questions and find answers to them ¯\_(ツ)_/¯.
The answer to each of them is actually yes or no. If all the answers are positive, it means that our colleague is "good enough" pizzerman.
Well, let's check it
We already have the questions so let's now look for the answers - let's play the role of the tester. To each question we will add a corresponding icon suggesting yes (✔️) or no (❌).
During testing, it turned out that the pizza tasted good to only half of the customers, so our colleague needs training. We gave him a few days and we ran the same tests again.
All questions have a positive answer, so our colleague can start work.
This particular questions and answers are mythical
tests. So, we can say that testing is nothing more than posing clear questions that can have only two possible answers (yes, no) and checking which answer it is.
If you enjoyed it, be sure to visit us onLinkedinwhere we regularly upload content from programming.
- 1. Basics
Grouping the tests
The usage of describe and it
The best practices for naming tests
Types of tests
- 2. Mastering unit testing