コード例 #1
0
 public PluginsTests()
 {
     this._model = WithValidPreflightChecks()
                   .ClickNext()
                   .ClickNext()
                   .ClickNext()
                   .IsValidOnStep(m => m.PluginsModel);
 }
コード例 #2
0
 public BasicLicenseModelTester()
 {
     this._model = DefaultValidModel()
                   .ClickNext()
                   .ClickNext()
                   .ClickNext()
                   .IsValidOnStep(m => m.PluginsModel)
                   .IsValidOnStep(m => m.PluginsModel)
                   .ClickNext();
 }
コード例 #3
0
 public BasicLicenseModelTester()
 {
     this._model = WithValidPreflightChecks()
                   .ClickNext()
                   .ClickNext()
                   .ClickNext()
                   .IsValidOnStep(m => m.PluginsModel)
                   .OnStep(m => m.PluginsModel, step =>
     {
         step.ChangeXPackSelection(true);
     })
                   .IsValidOnStep(m => m.PluginsModel)
                   .ClickNext();
 }
コード例 #4
0
        public void Application_Startup(object sender, StartupEventArgs e)
        {
            var previousVersion = "6.2.3";
            var currentVersion  = "7.0.0";
            var upgradeState    = InstallationModelTester.ValidPreflightChecks(s => s
                                                                               .Wix(current: "7.0.0", upgradeFrom: previousVersion)
                                                                               .Elasticsearch(es => es
                                                                                              .EsHomeMachineVariable($@"C:\elasticsearch\{previousVersion}")
                                                                                              .EsConfigMachineVariable($@"C:\ProgramData\{previousVersion}\config")
                                                                                              )
                                                                               .ServicePreviouslyInstalled()
                                                                               );

            var state = InstallationModelTester.ValidPreflightChecks(s => s
                                                                     .Wix(current: "7.0.0")
                                                                     );
            var model = state.InstallationModel;

            var window = new MainWindow(model, new ManualResetEvent(false));

            model.InstallUITask = async() =>
            {
                await Task.Delay(TimeSpan.FromSeconds(1));

                var customDialog = new CustomDialog {
                    Title = "Output"
                };
                var licenseModel = new LicenseModel();
                licenseModel.Close.Subscribe(async x => await window.HideMetroDialogAsync(customDialog));
                customDialog.Content = new LicenseDialog(model.ToMsiParamsString())
                {
                    DataContext = licenseModel
                };
                await window.ShowMetroDialogAsync(customDialog);

                return(Observable.Return(ClosingResult.Success));
            };
            model.AllSteps.Last().IsSelected = true;
            window.Show();

            RxApp.MainThreadScheduler = new DispatcherScheduler(Application.Current.Dispatcher);
            Application.Current.Resources["InstallerTitle"] = model.ClosingModel.CurrentVersion.ToString();
        }
コード例 #5
0
        public void Application_Startup(object sender, StartupEventArgs e)
        {
            var state = InstallationModelTester.ValidPreflightChecks(s => s
                                                                     .Wix(currentVersion: "6.1.0", existingVersion: "6.0.0")
                                                                     );
            var model = state.InstallationModel;

            var window = new MainWindow(model, new ManualResetEvent(false));

            model.InstallUITask = async() =>
            {
                await Task.Delay(TimeSpan.FromSeconds(1));

                return(Observable.Return(ClosingResult.Success));
            };
            model.AllSteps.Last().IsSelected = true;
            window.Show();

            RxApp.MainThreadScheduler = new DispatcherScheduler(Application.Current.Dispatcher);
            Application.Current.Resources["InstallerTitle"] = model.ClosingModel.CurrentVersion.ToString();
        }
コード例 #6
0
 public TrialLicenseModelTester()
 {
     this._model = DefaultValidModel()
                   .ClickNext()
                   .ClickNext()
                   .ClickNext()
                   .IsValidOnStep(m => m.PluginsModel)
                   .IsValidOnStep(m => m.PluginsModel)
                   .ClickNext()
                   .OnStep(m => m.XPackModel, step =>
     {
         step.XPackLicense = XPackLicenseMode.Trial;
     })
                   .IsInvalidOnStep(m => m.XPackModel, errors => errors
                                    .ShouldHaveErrors(
                                        XPackModelValidator.ElasticPasswordRequired,
                                        XPackModelValidator.KibanaPasswordRequired,
                                        XPackModelValidator.LogstashPasswordRequired
                                        )
                                    );
 }
コード例 #7
0
 public RunAsTests()
 {
     this._model = DefaultValidModel()
                   .ClickNext()
                   .IsValidOnStep(m => m.ServiceModel);
 }
コード例 #8
0
 public LocationsFlagTests()
 {
     this._model = DefaultValidModel()
                   .IsValidOnFirstStep();
 }
コード例 #9
0
 public WritableLocationsTests()
 {
     this._model = DefaultValidModel()
                   .IsValidOnStep(m => m.LocationsModel);
 }
コード例 #10
0
 public RunAsTests()
 {
     this._model = WithValidPreflightChecks()
                   .ClickNext()
                   .IsValidOnStep(m => m.ServiceModel);
 }
コード例 #11
0
 public LocationModelTests()
 {
     this._model = WithValidPreflightChecks()
                   .IsValidOnFirstStep();
 }
コード例 #12
0
 public WritableLocationsTests()
 {
     this._model = WithValidPreflightChecks()
                   .IsValidOnStep(m => m.LocationsModel);
 }