Apply solver change also to the parallel variant

This commit is contained in:
Ettore Di Giacinto 2020-12-08 10:41:03 +01:00
parent 7c53296530
commit 24201b25ef
2 changed files with 3 additions and 2 deletions

View File

@ -699,7 +699,7 @@ func (s *Parallel) Uninstall(checkconflicts, full bool, packs ...pkg.Package) (p
}
}
s2 := &Parallel{Concurrency: s.Concurrency, InstalledDatabase: pkg.NewInMemoryDatabase(false), DefinitionDatabase: s.DefinitionDatabase, ParallelDatabase: pkg.NewInMemoryDatabase(false)}
s2 := &Parallel{Concurrency: s.Concurrency, InstalledDatabase: pkg.NewInMemoryDatabase(false), DefinitionDatabase: s.InstalledDatabase, ParallelDatabase: pkg.NewInMemoryDatabase(false)}
s2.SetResolver(s.Resolver)
// Get the requirements to install the candidate
asserts, err := s2.Install(toRemove)

View File

@ -671,8 +671,9 @@ var _ = Describe("Parallel", func() {
Expect(err).ToNot(HaveOccurred())
Expect(solution).To(ContainElement(A))
Expect(solution).To(ContainElement(B))
Expect(len(solution)).To(Equal(1))
Expect(len(solution)).To(Equal(2))
})
It("Uninstalls complex packages correctly, even if shared deps are required by system packages", func() {