implemented image builder
Moved image class and test to a separate file