Skip to content

Commit a4b5ddd

Browse files
Modified a test to be implementation-independent.
1 parent bc70f57 commit a4b5ddd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/test/java/coreapiTest/OrderImplTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ public void GetProductsCheck()
7070
myOrder.addProduct(product1.getId());
7171
myOrder.addProduct(product2.getId());
7272
List<Product> tempList = myOrder.getProducts();
73-
Assert.assertEquals(product1.getId(), tempList.get(0).getId());
74-
Assert.assertEquals(product2.getId(), tempList.get(1).getId());
73+
Assert.assertEquals(product1.getId(), tempList.get(tempList.indexOf(product1)).getId());
74+
Assert.assertEquals(product2.getId(), tempList.get(tempList.indexOf(product2)).getId());
7575
}
7676

7777
@Test

0 commit comments

Comments
 (0)