diff options
author | Owen Lin <owenlin@google.com> | 2009-10-26 00:18:07 -0700 |
---|---|---|
committer | Owen Lin <owenlin@google.com> | 2009-10-29 21:44:06 -0700 |
commit | 79bc8acc67097c09907a71c4a5a72ab85eb58087 (patch) | |
tree | 568523f07085f8c8ad3839db5d3219d159919f2b /tests/src/com | |
parent | edafa3e7334aac23c7507afdeeb7c849d95b9d70 (diff) | |
download | packages_apps_LegacyCamera-79bc8acc67097c09907a71c4a5a72ab85eb58087.zip packages_apps_LegacyCamera-79bc8acc67097c09907a71c4a5a72ab85eb58087.tar.gz packages_apps_LegacyCamera-79bc8acc67097c09907a71c4a5a72ab85eb58087.tar.bz2 |
Remove unused code in Camera app.
Change-Id: I7b25fde19a172b6910d0217581cf61152d494a82
Diffstat (limited to 'tests/src/com')
-rw-r--r-- | tests/src/com/android/camera/gallery/ImageListUberUnitTests.java | 89 |
1 files changed, 0 insertions, 89 deletions
diff --git a/tests/src/com/android/camera/gallery/ImageListUberUnitTests.java b/tests/src/com/android/camera/gallery/ImageListUberUnitTests.java deleted file mode 100644 index 30487f2..0000000 --- a/tests/src/com/android/camera/gallery/ImageListUberUnitTests.java +++ /dev/null @@ -1,89 +0,0 @@ -package com.android.camera.gallery; - -import com.android.camera.ImageManager; - -import android.test.AndroidTestCase; - -public class ImageListUberUnitTests extends AndroidTestCase { - - public void testTheOrderOfGetImageAt() { - MockImageList listA = new MockImageList(); - MockImageList listB = new MockImageList(); - listA.addImage(new MockImage(2, 2)); - listA.addImage(new MockImage(0, 0)); - listB.addImage(new MockImage(1, 1)); - ImageListUber uber = new ImageListUber( - new IImageList[] {listA, listB}, ImageManager.SORT_DESCENDING); - - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(1, uber.getImageAt(1).fullSizeImageId()); - assertEquals(0, uber.getImageAt(2).fullSizeImageId()); - uber.close(); - - uber = new ImageListUber( - new IImageList[] {listA, listB}, ImageManager.SORT_DESCENDING); - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(1, uber.getImageAt(1).fullSizeImageId()); - assertEquals(0, uber.getImageAt(2).fullSizeImageId()); - uber.close(); - } - - public void testTheOrderOfGetImageAtCaseTwo() { - MockImageList listA = new MockImageList(); - MockImageList listB = new MockImageList(); - listA.addImage(new MockImage(2, 2)); - listA.addImage(new MockImage(1, 1)); - listB.addImage(new MockImage(0, 0)); - ImageListUber uber = new ImageListUber( - new IImageList[] {listB, listA}, ImageManager.SORT_DESCENDING); - - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(1, uber.getImageAt(1).fullSizeImageId()); - assertEquals(0, uber.getImageAt(2).fullSizeImageId()); - uber.close(); - - uber = new ImageListUber( - new IImageList[] {listA, listB}, ImageManager.SORT_DESCENDING); - - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(1, uber.getImageAt(1).fullSizeImageId()); - assertEquals(0, uber.getImageAt(2).fullSizeImageId()); - uber.close(); - } - - public void testRemoveImage() { - MockImageList listA = new MockImageList(); - MockImageList listB = new MockImageList(); - MockImage target = new MockImage(1, 1); - listA.addImage(new MockImage(2, 2)); - listA.addImage(new MockImage(0, 0)); - listB.addImage(target); - ImageListUber uber = new ImageListUber( - new IImageList[] {listB, listA}, ImageManager.SORT_DESCENDING); - uber.removeImage(target); - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(0, uber.getImageAt(1).fullSizeImageId()); - - assertEquals(0, uber.getImageIndex(uber.getImageAt(0))); - assertEquals(1, uber.getImageIndex(uber.getImageAt(1))); - uber.close(); - } - - public void testRemoveImageAt() { - MockImageList listA = new MockImageList(); - MockImageList listB = new MockImageList(); - MockImage target = new MockImage(1, 1); - listA.addImage(new MockImage(2, 2)); - listA.addImage(new MockImage(0, 0)); - listB.addImage(target); - ImageListUber uber = new ImageListUber( - new IImageList[] {listB, listA}, ImageManager.SORT_DESCENDING); - uber.removeImageAt(1); - assertEquals(2, uber.getImageAt(0).fullSizeImageId()); - assertEquals(0, uber.getImageAt(1).fullSizeImageId()); - - assertEquals(0, uber.getImageIndex(uber.getImageAt(0))); - assertEquals(1, uber.getImageIndex(uber.getImageAt(1))); - uber.close(); - } -} |