Pupils pick their healthy snacks
The new machines are intended as alternatives to the sugar-filled machines already on offer. So pupils were given extensive guidance on healthy eating, and the importance of a balanced diet.
Lynne Perry, health co-ordinator for the project, said: "Food for children is a high-profile issue at the moment. Pupils are aware of this, and are happy to start to swing the change."
In each school, pupil representatives from a range of age groups were asked for their snack-time priorities. Most suggestions, such as half-baguettes, yoghurts and fruit-salad, have been incorporated into the initiative.
Others, such as guavas or kiwi-fruit, were less practical.
"We wanted everything to cost less than pound;1," said Ms Perry. "It's very important to keep the price as low as possible.
"But we always gave good reasons why we could not include things."
The scheme will be launched officially on February 5, by Jane Hutt, Welsh Assembly health minister. After a year, the Assembly will decide how best to extend it across Wales.
Martin Lloyd, head of Preseli comprehensive, one of the schools to pilot the initiative, insists that the machines will convince pupils to break bad eating habits.
"Lots of kids gravitate towards chocolate," he said. "But we're hoping that, by offering a healthy option and showing why it's better, we can give pupils healthy-eating habits that will last after they've left school."
Thirteen-year-old Carys Vaughan helped to select the contents of the new machine. "My mum makes chips most nights, so at home I just eat what she cooks," she said. "But school is a chance to eat what I want to eat.
Sandwiches and fruit taste better, and keep you fit."
But her classmate Will Turner, 12, has yet to be convinced. "Sometimes you just feel like crisps, chocolate and sweets," he said. "Though sometimes you feel like a milkshake. That's healthier than a Coke, so it counts as healthy."