void CreateViewModel (FakePackageManagementSolution solution)
		{
			viewModelParent = CreateViewModelParent ();
			viewModel = new TestablePackageViewModel (viewModelParent, solution);
			fakePackage = viewModel.FakePackage;
			this.fakeSolution = solution;
			packageManagementEvents = viewModel.PackageManagementEvents;
			fakeLogger = viewModel.FakeLogger;
			fakeUninstallPackageAction = solution.FakeProjectToReturnFromGetProject.FakeUninstallPackageAction;
		}
Exemple #2
0
 TestableMonoDevelopProjectSystem(
     IDotNetProject project,
     IPackageManagementFileService fileService,
     IPackageManagementProjectService projectService,
     FakeLogger logger)
     : base(project, fileService, projectService, GuiSyncDispatcher)
 {
     FakeFileService    = (FakeFileService)fileService;
     FakeProjectService = (FakePackageManagementProjectService)projectService;
     Logger             = logger;
 }
		TestableMonoDevelopProjectSystem (
			IDotNetProject project,
			IPackageManagementFileService fileService,
			IPackageManagementProjectService projectService,
			FakeLogger logger)
			: base (project, fileService, projectService, GuiSyncDispatcher)
		{
			FakeFileService = (FakeFileService)fileService;
			FakeProjectService = (FakePackageManagementProjectService)projectService;
			Logger = logger;
		}
 public FakeInstallPackageAction(
     IPackageManagementProject project,
     IPackageManagementEvents packageManagementEvents,
     FakeFileRemover fileRemover,
     FakeLicenseAcceptanceService licenseAcceptanceService)
     : base(project, packageManagementEvents, fileRemover, licenseAcceptanceService)
 {
     FileRemover = fileRemover;
     LicenseAcceptanceService = licenseAcceptanceService;
     Operations = new List <PackageOperation> ();
     Logger     = new FakeLogger();
 }
 public TestablePackageViewModel(
     IPackageViewModelParent parent,
     FakePackage package,
     PackageManagementSelectedProjects selectedProjects,
     PackageManagementEvents packageManagementEvents,
     FakeLogger logger)
     : base(
         parent,
         package,
         selectedProjects,
         packageManagementEvents,
         null,
         logger)
 {
     this.FakePackage             = package;
     this.PackageManagementEvents = packageManagementEvents;
     this.FakeLogger = logger;
 }
		public TestablePackageViewModel (
			IPackageViewModelParent parent,
			FakePackage package,
			PackageManagementSelectedProjects selectedProjects,
			PackageManagementEvents packageManagementEvents,
			FakeLogger logger)
			: base (
				parent,
				package,
				selectedProjects,
				packageManagementEvents,
				null,
				logger)
		{
			this.FakePackage = package;
			this.PackageManagementEvents = packageManagementEvents;
			this.FakeLogger = logger;
		}
		public void Logger_SetLoggerWhenSourceRepositoryIsAggregateRepository_LoggerOnAggregateRepositoryIsSet ()
		{
			var aggregateRepository = new AggregateRepository (new FakePackageRepository [0]);
			CreateProject (aggregateRepository);
			var expectedLogger = new FakeLogger ();

			project.Logger = expectedLogger;

			Assert.AreEqual (expectedLogger, aggregateRepository.Logger);
		}
		public void Logger_SetLogger_LoggerOnPackageManagerIsSet ()
		{
			CreateProject ();
			var expectedLogger = new FakeLogger ();

			project.Logger = expectedLogger;

			Assert.AreEqual (expectedLogger, fakePackageManager.Logger);
		}
		public FakeInstallPackageAction (IPackageManagementProject project, IPackageManagementEvents packageManagementEvents)
			: base (project, packageManagementEvents)
		{
			Operations = new List<PackageOperation> ();
			Logger = new FakeLogger ();
		}
 public FakeInstallPackageAction(IPackageManagementProject project, IPackageManagementEvents packageManagementEvents)
     : base(project, packageManagementEvents)
 {
     Operations = new List <PackageOperation> ();
     Logger     = new FakeLogger();
 }