Skip to content

Commit

Permalink
Merge pull request #20 from King-of-Spades/FormsGallery
Browse files Browse the repository at this point in the history
Add Xamarin.Forms Control Gallery sample along with working Xamarin.UITests for each element
  • Loading branch information
King-of-Spades authored Jan 5, 2019
2 parents c1afb49 + 4c8bff8 commit 3200037
Show file tree
Hide file tree
Showing 234 changed files with 16,285 additions and 0 deletions.
44 changes: 44 additions & 0 deletions Xamarin.UITest/FormsGallery/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Autosave files
*~

# build
[Oo]bj/
[Bb]in/
packages/
TestResults/

# globs
Makefile.in
*.DS_Store
*.sln.cache
*.suo
*.cache
*.pidb
*.userprefs
*.usertasks
config.log
config.make
config.status
aclocal.m4
install-sh
autom4te.cache/
*.user
*.tar.gz
tarballs/
test-results/
Thumbs.db

# Mac bundle stuff
*.dmg
*.app

# resharper
*_Resharper.*
*.Resharper

# dotCover
*.dotCover

Droid/Resources/Resource.designer.cs

.vs
46 changes: 46 additions & 0 deletions Xamarin.UITest/FormsGallery/FormsGallery.UITest/AppInitializer.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
using System;
using System.IO;
using System.Linq;
using Xamarin.UITest;
using Xamarin.UITest.Queries;

namespace FormsGallery.UITest
{
public class AppInitializer
{
public static IApp StartApp(Platform platform)
{
// TODO: If the iOS or Android app being tested is included in the solution
// then open the Unit Tests window, right click Test Apps, select Add App Project
// and select the app projects that should be tested.
//
// The iOS project should have the Xamarin.TestCloud.Agent NuGet package
// installed. To start the Test Cloud Agent the following code should be
// added to the FinishedLaunching method of the AppDelegate:
//
// #if ENABLE_TEST_CLOUD
// Xamarin.Calabash.Start();
// #endif
if (platform == Platform.Android)
{
return ConfigureApp
.Android
// TODO: Update this path to point to your Android app and uncomment the
// code if the app is not included in the solution.
//.ApkFile ("../../../Droid/bin/Debug/xamarinforms.apk")
.StartApp();
}


Environment.SetEnvironmentVariable("UITEST_FORCE_IOS_SIM_RESTART", "1");

return ConfigureApp
.iOS
// TODO: Update this path to point to your iOS app and uncomment the
// code if the app is not included in the solution.
//.AppBundle ("../../../iOS/bin/iPhoneSimulator/Debug/XamarinForms.iOS.app")

.StartApp();
}
}
}
Loading

0 comments on commit 3200037

Please sign in to comment.