some small changes to get test_scenarios etc. to work rather than just optima