#1553: added remaining unit tests to create and run optimizer samples.