summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorE.Z. Hart <hartez@gmail.com>2016-12-28 23:42:17 (GMT)
committerE.Z. Hart <hartez@gmail.com>2016-12-28 23:42:17 (GMT)
commitcf496381ce42bf458f66dc52c3504bf456d78579 (patch)
treef3e1ae023199dc5351ce304fd0c9dc409d465175
parent31397e59ccb8704f49e6f7e071424ab454489cfc (diff)
downloadxamarin-forms-cf496381ce42bf458f66dc52c3504bf456d78579.zip
xamarin-forms-cf496381ce42bf458f66dc52c3504bf456d78579.tar.gz
xamarin-forms-cf496381ce42bf458f66dc52c3504bf456d78579.tar.bz2
Update ImageCellListPage to use an image we control;
Update CellsGalleryImageUrlCellList test to wait longer than 1s for images to load if necessary
-rw-r--r--Xamarin.Forms.Controls/GalleryPages/CellsGalleries/ImageCellListPage.cs2
-rw-r--r--Xamarin.Forms.Core.iOS.UITests/Tests/Legacy-CellsUITests.cs12
2 files changed, 11 insertions, 3 deletions
diff --git a/Xamarin.Forms.Controls/GalleryPages/CellsGalleries/ImageCellListPage.cs b/Xamarin.Forms.Controls/GalleryPages/CellsGalleries/ImageCellListPage.cs
index e708647..62ec694 100644
--- a/Xamarin.Forms.Controls/GalleryPages/CellsGalleries/ImageCellListPage.cs
+++ b/Xamarin.Forms.Controls/GalleryPages/CellsGalleries/ImageCellListPage.cs
@@ -94,7 +94,7 @@ namespace Xamarin.Forms.Controls
var albums = new List<string> ();
for (int i = 0; i < 30; i++) {
- albums.Add (string.Format ("http://cdn.instructables.com/FCP/9TOJ/GCJ0ZQV5/FCP9TOJGCJ0ZQV5.MEDIUM.jpg?ticks={0}",i ));
+ albums.Add (string.Format ("https://raw.githubusercontent.com/xamarin/Xamarin.Forms/master/Xamarin.Forms.Controls/coffee.png?ticks={0}", i ));
}
diff --git a/Xamarin.Forms.Core.iOS.UITests/Tests/Legacy-CellsUITests.cs b/Xamarin.Forms.Core.iOS.UITests/Tests/Legacy-CellsUITests.cs
index 4d7ec9d..ca275c8 100644
--- a/Xamarin.Forms.Core.iOS.UITests/Tests/Legacy-CellsUITests.cs
+++ b/Xamarin.Forms.Core.iOS.UITests/Tests/Legacy-CellsUITests.cs
@@ -113,8 +113,16 @@ namespace Xamarin.Forms.Core.UITests
App.Screenshot("All ImageCells are present");
- await Task.Delay(1000);
- var numberOfImages = App.Query(q => q.Raw(PlatformViews.Image)).Length;
+ int numberOfImages = 0;
+
+ // Most of the time, 1 second is long enough to wait for the images to load, but depending on network conditions
+ // it may take longer
+ for (int n = 0; n < 30; n++)
+ {
+ await Task.Delay(1000);
+ numberOfImages = App.Query(q => q.Raw(PlatformViews.Image)).Length;
+ }
+
// Check that there are images present. In Android,
// have to make sure that there are more than 2 for navigation.
Assert.IsTrue(numberOfImages > 2);