public async void Install() { var chocolateyInstaller = new ChocolateyInstaller(new ProcessRunner(), new PowerShellRunner()); await chocolateyInstaller.InstallChocolatey(null, null); Assert.IsTrue(chocolateyInstaller.IsInstalled()); }
public void ReCheck() { if (chocolateyInstaller.IsInstalled()) { eventAggregator.Publish <UserInstalledChocolatey>(); } }
public async void Handle(RunInstallEvent message) { installWasAttempted = true; itemsToInstall = message.SelectedItems; if (chocolateyInstaller.IsInstalled()) { var chocolateyUpgradeRequired = await chocolateyInstaller.ChocolateyUpgradeRequired(); if (chocolateyUpgradeRequired) { ActivateModel <UpdateChocolateyViewModel>(); return; } ActivateInstallingViewModel(); return; } ActivateModel <InstallChocolateyViewModel>(); }
public async void ReCheck() { try { CanAcceptInput = false; await RefreshDetectedVersion(); var chocolateyUpgradeRequired = await chocolateyInstaller.ChocolateyUpgradeRequired(); if (chocolateyInstaller.IsInstalled() && !chocolateyUpgradeRequired) { eventAggregator.Publish <UserInstalledChocolatey>(); } } finally { CanAcceptInput = true; } }
public void IsInstalled() { var chocolateyInstaller = new ChocolateyInstaller(new ProcessRunner(), new PowerShellRunner()); Assert.IsTrue(chocolateyInstaller.IsInstalled()); }