public TestablePackageViewModel(
            IPackageViewModelParent parent,
            FakePackage package,
            PackageManagementSelectedProjects selectedProjects,
            FakePackageManagementEvents packageManagementEvents,
            FakePackageActionRunner actionRunner,
            FakeLogger logger)
            : base(
                parent,
                package,
                selectedProjects,
                packageManagementEvents,
                actionRunner,
                logger)
        {
            this.FakePackage = package;
            this.FakePackageManagementEvents = packageManagementEvents;
            this.FakeActionRunner            = actionRunner;
            this.FakeLogger = logger;

            IsProjectPackageReturnsValue = true;
            IsProjectPackageIsCalled     = false;

            IsProjectPackageAction = p => {
                IsProjectPackageIsCalled = true;
                return(IsProjectPackageReturnsValue);
            };
        }
 public PackageViewModel CreatePackageViewModel(IPackageViewModelParent parent, IPackageFromRepository package)
 {
     SelectedProjects = new PackageManagementSelectedProjects(FakeSolution);
     return(new PackageViewModel(
                parent,
                package,
                SelectedProjects,
                PackageManagementEvents,
                null,
                FakeLogger));
 }
Ejemplo n.º 3
0
 public TestablePackageViewModel(
     FakePackage package,
     PackageManagementSelectedProjects selectedProjects,
     FakePackageManagementEvents packageManagementEvents,
     FakePackageActionRunner actionRunner,
     FakeLogger logger)
     : base(
         package,
         selectedProjects,
         packageManagementEvents,
         actionRunner,
         logger)
 {
     this.FakePackage = package;
     this.FakePackageManagementEvents = packageManagementEvents;
     this.FakeActionRunner            = actionRunner;
     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 UpdatedPackagesViewModel2 (
			IPackageManagementSolution solution,
			IRegisteredPackageRepositories registeredPackageRepositories,
			UpdatedPackageViewModelFactory2 packageViewModelFactory,
			ITaskFactory taskFactory)
			: base (
				registeredPackageRepositories,
				packageViewModelFactory,
				taskFactory)
		{
			this.selectedProjects = new PackageManagementSelectedProjects (solution);
			this.logger = packageViewModelFactory.Logger;
			this.packageManagementEvents = packageViewModelFactory.PackageManagementEvents;

			packageManagementEvents.ParentPackagesUpdated += PackagesUpdated;

			ShowPackageSources = true;
			ShowUpdateAllPackages = true;
			ShowPrerelease = true;
		}
Ejemplo n.º 6
0
 void CreateSelectedProjects()
 {
     selectedProjects = new PackageManagementSelectedProjects(fakeSolution);
 }
Ejemplo n.º 7
0
 public FakePackageViewModelFactory()
 {
     SelectedProjects = new PackageManagementSelectedProjects(FakeSolution);
 }