In essence the level of testing done is determined by the level of risk from the product failing. Whilst with the chocolate manufacturer, the level of risk, if their chocolates fail to live up to the standards set, would be a loss of sales and the loss of their image and brand.
The plane manufacturer, the risks involved are much higher as there would be the loss of life, as well as the loss of sales and the loss of image/brand to contend with.
Simply by introducing the element of an increased possibility of the loss of life through the failure of a product, substantially increases the risks involved with that particular product.
The plane manufacturer to counter the risks involved must test all the planes that they produce, however that doesn't mean that they are fully tested. Only the components that are critical are tested per plane, others are tested at the prototype stage.
It's akin to baking a cake, initially there is uncertainty of what quantity of ingredients are required. But as soon as this is realised, any subsequent cakes baked don't require the trial and error measuring to see if the ingredients are in the right quantities.
The higher the risks involved the greater detail of testing done.
The same applies with the plane, once you know how thick the fuselage metal skin needs to be, there is no need to test this further to see whether this thickness can withstand stresses and strains. The only tests required would be tests to seek out any imperfections in the fuselage.
The level of testing is of the utmost importance. Testing something more or less than it should be can also be a risk. For the plane manufacturer, spending a disproportionately longer time testing the smoke alarms in the planes toilets than the effectiveness of the door seals, will introduce a higher risk.
Whilst the smoke alarms failing are not going to be life threatening, the same can't be said for the door seals failing. As such, a failure would create rapid depressurisation and potentially could cause the plane to crash.