Programming basics for testers (read, don't build)
Read variables, loops, functions, strings and lists well enough to follow any check, with tested answers to common coding questions.
L1–L4 are part of the Pro pass
L0 Explain simply
Analogy: reading a menu. You do not need to cook to read a menu. You need enough of the language to know that "soup" is soup and "spicy" means spicy. You do not need to run the kitchen.
Tom is in the same spot with code. Leo's check has a name for a thing, a repeat over three tasks and a small helper. Tom does not need to build a program. He needs to read these three things.
A variable is a named box that holds a value. The name count might hold 3. A loop repeats steps for each item. A function is a named block of steps that gives back a result.
With those three ideas, plus strings and lists, Tom can follow most checks. When fails, he can say which line is odd.
The picture has limits. A menu is fixed, but code has small strict rules. A missing quote or a wrong space can stop the whole program.
(SYNTHETIC / TRAINING ONLY: Daily List and every person named in this lesson are invented.)
PICTURE IT
The picture is the one the lesson above opens with. The table below shows how each part of it matches the software.
THE REAL JOB Reading variables, loops, functions and lists well enough to follow and spot an odd line.
- Spot the names
- Spot the repeats
- Spot the helpers
- Test the edges
HOW THE PICTURE MAPS
| In the picture | In the software |
|---|---|
| The menu | The code in a check |
| A dish name | A variable name |
| Serve each table in turn | A loop |
| A recipe you can reuse | A function |
WHERE THIS PICTURE STOPS
- A menu is fixed. Code has strict small rules.
- A waiter can guess what you mean. A program cannot.
- A menu has no mistakes to hunt. Code does.
HOOK
Name it, repeat it, reuse it.
REMEMBER IT THIS WAY
A contrast: two neighbours told apart by one test.
Is this line a box, a repeat or a helper? A variable holds a value, a loop repeats for each item, a function gives back a result.
| In the trick | What it stands for |
|---|---|
| Box | A variable name |
| Repeat | A loop |
| Helper | A function |
TELL A FRIEND
A menu is read without cooking, and code in is read without building. The three pieces are boxes, repeats and helpers.
OFTEN MIXED UP WITH Reading an automated check. The reading lesson finds the parts of . This lesson reads the code inside them.
PRACTISE AND KEEP
Sources for this topic — 6 sources
- Market practice
More Control Flow Tools (Python tutorial) ↗ — Python Software Foundation · The tutorial covers for loops, range and defining functions in Python (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
- Market practice
Data Structures (Python tutorial) ↗ — Python · Lists, sets without duplicates and dictionaries of key-value pairs with unique keys; lists cannot be dictionary keys (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
- Market practice
The Catch or Specify Requirement (The Java Tutorials) ↗ — Oracle · A method that can throw a checked exception must catch it or list it in a throws clause; the throw statement signals an error (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
- Market practice
Comparing Strings and Portions of Strings (The Java Tutorials) ↗ — Oracle · Java strings are compared with equals, equalsIgnoreCase and compareTo (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
- Market practice
Install a Selenium library (Selenium documentation) ↗ — Selenium project · How a Java project lists the Selenium library with a version in its build file, and how other languages install it (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
- Market practice
A4Q Certified Selenium Tester Foundation Level (iSQI course listing) ↗ — iSQI · The course listing names library management for WebDriver tests (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.
Deepest material on this page: L4 — Standards & sources. Where a topic stops short of implementation depth, that is a deliberate coverage decision, not an oversight — see coverage.