Skip to content

Commit

Permalink
Get tests passing
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Sumner committed Apr 11, 2016
1 parent 64f455a commit e8fab32
Showing 1 changed file with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,20 @@ public List<ImageResult> listStoryboardImages(String folder, String fragment) {
ArrayList<ImageResult> list = new ArrayList<ImageResult>();
int pos = 0;
while ((pos=fragment.indexOf(TEXT_BEFORE_IMAGE_NAME, pos)) != -1) {
ImageResult result = new ImageResult();
pos = pos + TEXT_BEFORE_IMAGE_NAME.length();
result.imageName = fragment.substring(pos, fragment.indexOf("\"", pos));
String imageName = fragment.substring(pos, fragment.indexOf("\"", pos));
pos++;
File file = new File(new File(getBaseOutputDir(), folder), result.imageName);

int index = imageName.indexOf("?");
if (index > 0) {
imageName = imageName.substring(0, index);
}

File file = new File(new File(getBaseOutputDir(), folder), imageName);
System.out.println("looking for " + file.toString());

ImageResult result = new ImageResult();
result.imageName = imageName;
result.storedOnDisk = file.exists();
list.add(result);
}
Expand Down

0 comments on commit e8fab32

Please sign in to comment.