protected override void OnCreate(Bundle bundle) { base.OnCreate(bundle); // Set our view from the "main" layout resource SetContentView(Resource.Layout.Main); // Get our button from the layout resource, // and attach an event to it Button button = FindViewById<Button>(Resource.Id.MyButton); //button.Click += delegate { button.Text = string.Format("{0} clicks!", count++); }; button.Click += OnClick; var txtBox = FindViewById<TextView>(Resource.Id.TestOutput); txtBox.Text = "Executing tests..."; try { runner = new AndroidRunner(txtBox, RunOnUiThread); runner.ExecuteAllTestsAsync(); } catch(Exception e) { txtBox.Text = e.ToString(); } }
protected override void OnCreate(Bundle bundle) { base.OnCreate(bundle); // Set our view from the "main" layout resource SetContentView(Resource.Layout.Main); // Get our button from the layout resource, // and attach an event to it Button button = FindViewById<Button>(Resource.Id.MyButton); //button.Click += delegate { button.Text = string.Format("{0} clicks!", count++); }; button.Click += OnClick; var txtBox = FindViewById<TextView>(Resource.Id.TestOutput); txtBox.MovementMethod = new ScrollingMovementMethod(); var stream = Assets.Open(CredentialsAsset); txtBox.Text = "Executing tests..."; runner = new AndroidRunner(stream, txtBox, RunOnUiThread); runner.ExecuteAllTestsAsync(); }
private static SpecificTestsFilter Create_Categories(TestRunner runner, ICollection<string> categories, bool isRunOnly) { return new SpecificTestsFilter(runner) { _categories = categories ?? new HashSet<string>(), _isRunOnly = isRunOnly }; }
private static SpecificTestsFilter Create_Tests(TestRunner runner, ICollection<string> tests, bool isRunOnly) { return new SpecificTestsFilter(runner) { _tests = tests ?? new HashSet<string>(), _isRunOnly = isRunOnly }; }
public static SpecificTestsFilter RunAllCategoriesExcept(TestRunner runner, ICollection<string> categoriesToSkip) { return Create_Categories(runner, categoriesToSkip, isRunOnly: false); }
public static SpecificTestsFilter RunOnlyCategories(TestRunner runner, ICollection<string> categoriesToRun) { return Create_Categories(runner, categoriesToRun, isRunOnly: true); }
public static SpecificTestsFilter RunAllTestsExcept(TestRunner runner, ICollection<string> testsToSkip) { return Create_Tests(runner, testsToSkip, isRunOnly: false); }
public static SpecificTestsFilter RunOnlyTests(TestRunner runner, ICollection<string> testsToRun) { return Create_Tests(runner, testsToRun, isRunOnly: true); }
private SpecificTestsFilter(TestRunner runner) { _runner = runner; }
protected override void OnNavigatedTo(NavigationEventArgs e) { this.TestRunner = new WindowsAppRunner(dispatcher, this.textBox); }
protected override void OnNavigatedTo(NavigationEventArgs e) { this._runner = new WindowsAppRunner(dispatcher, this.textBox); this._runner.ExecuteAllTestsAsync(); }