improve tests to deal with scaled images