public void Should_detect_when_multiple_projects_exist_with_correct_count_when_three_and_chosen() { var tempPath = GetPathWithThreeProjects(); var bs = new AppBootStrapper(tempPath); bs.SetProjectName("Project1"); bs.DetectProjectMode().Should().Be(AppProjectsStructureMode.MultipleChosen); }
public void Should_detect_when_multiple_projects_exist_with_correct_count_when_three_and_chosen_but_doesnt_exist() { var tempPath = GetPathWithThreeProjects(); var bs = new AppBootStrapper(tempPath); Exception exception = null; try { bs.SetProjectName("Project45"); } catch (Exception ex) { exception = ex; } exception.Should().NotBeNull(); }
private void acceptAndContinueBarButtonItem_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) { var item = multipleProjectsListBoxControl.SelectedItem as string; if (string.IsNullOrWhiteSpace(item)) { MessageBox.Show("Please retry", "Item was not selected, please try again"); return; } try { _bootStrapper.SetProjectName(item); Close(); } catch (Exception ex) { MessageBox.Show("Error", "An error has happened: \r\n" + ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); } }