Some time ago I was interviewed for the position of a QA engineer in a famous Russian IT company. I was offered a task, whose solution, with the permission of the company, I published in my blog. The post turned out to be very popular, in a short time having gained several thousand views, and it seemed to me a bright idea to duplicate it on Habré. According to the rules of Habra, the text is published without emoticons.
So, the task was as follows:
it is necessary to describe the steps for comprehensive testing of a simple pencil with an eraser at one of the ends.Solution - under the cut.
')
Since pencils are a wonderful and favorite subject in general, I have received an unspeakable pleasure from this task. In the process of thinking and searching for information, many new and interesting things were discovered, which I had never suspected before ...
So, we have a pencil:

By the condition of the problem, since no additional conditions are specified, therefore we assume that:
1. The pencil is not mechanical, but it is simple - wooden or plastic. About the color does not say - so. pencil can be colored. In fact, this condition only says that this pencil is more suitable for drawing than for simple notes and drawing; Of course, it’s not a fact, but we’ll set this condition as irrelevant - we will deliberately not consider testing pencils of different colors. If desired, consider this issue separately.
2. Initially, it is not known whether the manufacturer sharpened a pencil in a factory or not - we consider both cases.
3. The elastic is fixed and located on the opposite end of the pencil.
4. If we assume that we have only one copy of the pencil, then the testing can be conducted not on all items - the testing functionality will noticeably narrow, since a pencil, alas, a resource that is not recoverable - it needs to be sharpened, they need to write, and also do various other interesting things with it.
5. Nothing is said about the packaging, the manufacturer and the parameters of the pencil. We assume that we still have them / know / see. With the reverse testing functionality will be somewhat less.
General criteria for evaluating tests:The main evaluation criteria will be the fulfillment / non-fulfillment of the conditions of the specified tests. If the test is performed, you can evaluate the result by some predetermined rules (for example, on a ten-point scale, 0 is horrible, 10 is excellent; and, in general, the evaluation criterion can be set as you please). Some additional parameters will try to present in numerical terms. Based on the data obtained, it is possible to create summary characteristics of various models of pencils.
Basic Test Cases for pencil testing will look something like this.
Initial properties "out of the box" or "quick inspection" (primary testing):- If the pencil was originally sharpened: make sure that they can write "by default". Some manufacturers of pencils manage to sharpen them in such a way that they need to be pre-sharpened again, because when sharpening by default, they simply do not write.
- If the pencil was not originally sharpened: is it convenient for us in the current conditions to have a pencil that is not sharpened “by default” (for example, when there is no sharpener or office knife at hand)? Those. whether additional "initialization" of the pencil in the form of its preliminary sharpening is required.
- Make sure that the gum at the end of the pencil does not come off when you first touch it and holds tight - at least visually.
- Is there a marking on the pencil denoting (degree of hardness, rod diameter, purpose, specific parameters)? Is the manufacturer listed?

- What is the shape of the rod: round, hexagonal, triangular, oval with a wide slate? In practice, pencils with a round rod are more suitable for drawing, hexagonal - for writing and sketching (when drawing the hand is less tired with a round shape, while writing and sketching - with a hexagonal). Pencils with a triangular barrel are convenient for children and people with disabilities - in the case when the hand does not hold the pencil well.
- The core of wood or plastic?
- Is there a varnish on the pencil?
- Pay attention to the box and packaging, as well as labeling on them: the manufacturer and all the parameters of the pencil.
Product quality (quality estimation):- On the pencil there is no burrs, irregularities, drips from varnish, other untidiness and factory marriages.
- The marking (if any) is applied qualitatively, the inscriptions are not blurred and clearly readable.
- The gum holder is flat, does not cling to clothing and skin.
Usability testing:- The pencil is easy to hold. When working, it does not slip and does not fall out.
- Is there a “gripping zone” on the pencil - special paint sticks that do not allow the pencil to slide in your hand (2001, Faber Castell). See previous paragraph.
- For the visually impaired: the use of pencils with a hexagonal or triangular barrel is important. A round barrel pencil, rolled under the table, is often a serious problem for a visually impaired person.
Usage (functional testing):Draw on paper.

- Make sure that the pencil at all draws.
- Make sure that the color of the text / the quality of the drawing / drawing corresponds to the hardness of the pencil (rich, pale, retouching, etc ...
- Let's check the behavior of the pencil under strong pressure with a pencil lead on the paper. Ensure that the pencil does not break.
- Pull the pencil lead. It should not come out of the trunk.
- Knock a pencil on the table several times. The stylus should not crumble or break, fall out of the trunk, crack.
- Stylus does not break and does not crumble, and directly when drawing.
- The pencil does not stain hands and clothes, does not leave additional marks on the figure.
- When drawing the barrel of a pencil is clean, it does not collect microbes and dirt from his hands. Best of all in this sense are pencils with a lacquered barrel.
We use gum on the pencil.

- How much does a rubber band at the end of a pencil make sense at all - is it more at work or does it interfere more?
- Eraser erases writing / drawings, does not smear and does not "dirty".
- Erase with time does not "dubeet" and continues to perform its functions.
- After use, the gum does not lag behind the pencil, does not peel off and does not fall out; the holder does not bend and does not leave marks and scratches on paper and hands.
- The pencil writes on those places on which records were erased with an eraser.
- We will do the same with a rubber band taken
not from a pencil .

- Now we will draw and then write in pencil: all the same actions, but in slightly different initial conditions (before that we drew). Different pencils are designed for different purposes: school, stationery, drawing, drawing (more than 370 (!) Different types and types of pencils are produced in the world, so there is a lot of room for imagination).
- Next, we will try to draw / draw / write not on paper, but on alternative materials - thick paper, cardboard, newspaper, wooden block, walls, floor (relevant for repair and construction works).

- Draw a carbon copy. There should be no specific problems.
- Storage and transportation: Does the pencil fit into the pencil holder (do the parameters match)? How convenient is it to fit and carry in your pocket, in your bag? Does it not prick, does not break, does not crumble? ..
ECO testing:- If the pencil barrel is coated with varnish: is a polymer or water based varnish used?
This item can also be attributed to product safety testing. Unfortunately, it’s impossible to find out 100% for all pencils - it’s not always written on the box. Is that chemical analysis will help.

This requirement is very relevant, because very often children (and not only!) Simply “eat” pencils. According to my calculations, I myself eat a few pencils a year. How many with this I will get harmful substances from such a habit, if the pencil is not safe - science is not known for sure. If you wish, you could try to calculate, but something you do not want ...
From the point of view of environmental friendliness, the best pencils are non-varnished and without gum (by the way, they are found in great numbers in Ikea, Leroy Merlen shops, etc.). And it is for this reason that I personally dislike pencils with a rubber band at the end - IMHO have it, and especially the iron holder is doubly inconvenient.
Security (security testing):- Is it possible to get hurt with a pencil (scratch, cut yourself when sharpening, is eyeliner dangerous)?
- Is it possible to give a pencil to a child? There are "safe" types of pencils (for example, special "children's", often with a triangular stem) that can be given to children safely (naturally, guided by age, overall development and characteristics of the child).

- Is the pencil safe for people with disabilities (for example, for the visually impaired)?
- Does the pencil meet the accepted standards (ISO, GOST, etc ...).
Appearance (ergonomic and usability testing):- The color of the pencil. “Classic” yellow trunk in the style of “Koh-I-Noor” or alternative non-classic? When choosing a pencil, people are guided by different considerations.
- The overall attractiveness, design and design.
- The barrel is round, triangular or hexagonal.
- Packaging / design brings or does not bring aesthetic satisfaction and is generally pleasing to the eye or not.

Here you can have additional data and make additional conclusions: what is the potential target audience of customers of this model, how well it will be sold and in what places, what are its main marketing properties, whether you need to advertise, how and how much money to spend on advertising, etc. . I am not a marketer, but I can assume that behind this lies a separate big topic that it will be difficult to solve here.
Sharpening pencilPossible variations of sharpening:
- We sharpen pencil sharpener.
- Sharpen sandpaper (relevant for soft pencils and pencils for retouching).
- Sharpen razor.
- Sharpen stationery knife.
- We sharpen with a kitchen knife (with a cleaver, medical scalpel, etc.)
- In the absence of sharpening tools, we sharpen (try) tools that are unsuitable for this (for example, teeth, a piece of glass, or a fork). As a result, most likely, there will be epic fail, but nevertheless it has a place to be.

Evaluation criteria for sharpening (for each tool):
- The pencil is generally sharpened by this tool. For example, it would be very difficult to sharpen a pencil with a plastic barrel with the help of a skin or a dangerous razor. Sharpening a small (ground) pencil with the help of a hunting cleaver will also be problematic.
- Pencil sharpens easily. A very relevant test: some sharpening pencils turn out to be absolutely “iron” and cannot be sharpened in principle (I personally observed such an example on pencils from a well-known manufacturer).
- In the process of sharpening and after it, the lead did not violate its integrity.
- In the process of sharpening and after it the pencil does not break and does not crumble.
- The barrel of the pencil is not stratified, after sharpening there are no agnails, irregularities and other damages.
- Slate does not fall out of the barrel.
- For varnished pencils: varnish does not peel off pieces from the trunk and does not crumble.
- The sharpened pencil successfully functions (you can write, draw, draw).
- Sharpening success rate K = M / N, where M is the number of successful sharpening, N is the number of unsuccessful sharpening. The smaller the K, the worse the pencil is sharpened with this tool.
Then we act according to the principle “We are trying to break everything that breaks” (so that later everything would work correctly, of course).
Use in extreme conditions (stress testing):- Drop the pencil on the floor several times. Ideally, the stylus should not break or crumble. Pencil barrel should not be damaged.
- Try to bend the pencil with an effort: break or not?
- We gnaw a pencil with a special zeal. The end of the pencil should not be "eaten." Many manufacturers pay special attention to this moment.
We love Ikea pencils!
They are small - fit in a small bag.
They are strong - you can drop a few times.
They are delicious - you can nibble- Put the pencil in the water, then dry it.
- Put a pencil in an acid, alkaline environment for a while.
- Freeze and then warm it up. Option - put in the snow in the cold.
- Heat the pencil, then cool. But we will not set it on fire anyway. This, of course, is also possible, although it is unlikely that after such a procedure it will be possible to use it, unless you imagine James Bond’s pencil, which does not burn in the fire and does not sink in water.

- If the testing budget is not limited or testing is well paid by the manufacturer for promotional purposes - we will conduct tests in zero gravity conditions. The astronauts on the ISS for specific reasons arising in zero gravity, by the way, use ordinary slate pencils ...

Each of the manipulations described above will somehow have a certain effect on the pencil. After each iteration we test the use of a pencil (see functional testing), we make sharpening. We will not test the appearance anymore - there are suspicions that if we perform all the above-mentioned manipulations on a pencil, then this will no longer be a pencil, but at best some of its similarity.
Performance testing (performance testing, or finally a bit of simple mathematics):We will try to measure the performance of a pencil: how many pages of text / drawings it is enough. You can do it manually, but the problem is that it will be a very long and laborious process, since it is quite difficult to draw a whole (especially well made) pencil. You can do all the operations manually, or you can use elementary mathematics.
Imagine that there are some empirically calculated averages: how many pages of text / figures can be drawn with a pencil of a certain length, hardness, a certain shape and with a certain diameter of the rod. Let it be called “Pencil efficiency” and will be X A4 pages (or X kilometers of text) for a pencil of length Y, see (we take data: from the manufacturer, on Google, in library sources - underline). Suppose also that the empirical calculations are a little inaccurate and use a pencil length “under zero”, and since it is very difficult to use a pencil less than 4 cm long, plus 1 cm for an eraser with a holder, we still have “real” work (Y - 5 ) cm. One sharpening “takes away” a pencil about 1 cm in length, therefore for one pencil of standard length 18 cm. we have about 13 sharpenings. When sharpened, the pencil may break. We consider how many unsuccessful sharpenings were made during the work of the pencil; let this number be equal to N. Let the pencil length be equal to L cm. Then:
Real pencil efficiency = (L - 5 - N) * (X / Y)It can be assumed that after the pencil is already half cut, the number of unsuccessful sharpening will increase in some way, for example, by a factor of K. Then:
Real pencil efficiency = ((L - 5 - N) / 2 + (L - 5 - K * N) / 2) * (X / Y)It is possible and in another way: we will count the number of successful sharpening, based on real data obtained experimentally during sharpening a pencil. Let it be V. Then:
Real Pencil Efficiency = V * X / YIt is clear that the calculations are very conditional, and if you want you can complicate the calculations, come up with more accurate criteria - this example does not aim to accurately calculate the efficiency of the pencil, but simply shows that this measurement is subject to mathematical calculations.
PS:You can think of a lot more. For sure.
In the process of thinking about these actions, I actively used an ordinary pencil. True, without gum.
The test result can be represented in graphical form.
