Exemplo n.º 1
0
    def test_make_link_operation(self):
        package_installer = PackageInstaller("prefix", {}, self.dist)
        package_installer.package_info = self.package_info
        output = package_installer._make_link_operations(LinkType.hard_link)
        expected_output = tuple([LinkOperation("test/path/1", "test/path/1", LinkType.copy,
                                               "/opt/anaconda1anaconda2anaconda3", FileMode.text,
                                               False),
                                 LinkOperation("test/path/2", "test/path/2", LinkType.copy, "",
                                               None, False),
                                 LinkOperation("test/path/3", "test/path/3", LinkType.copy, "",
                                               None, False),
                                 LinkOperation("menu/test.json", "menu/test.json",
                                               LinkType.hard_link, "", None, True)])

        self.assertEquals(output, expected_output)
Exemplo n.º 2
0
    def test_make_link_operation(self):
        package_installer = PackageInstaller("prefix", {}, self.dist)
        package_installer.package_info = self.package_info
        output = package_installer._make_link_operations(LinkType.hardlink)
        expected_output = tuple([LinkOperation("test/path/1", "test/path/1", LinkType.copy,
                                               "/opt/anaconda1anaconda2anaconda3", FileMode.text,
                                               False),
                                 LinkOperation("test/path/2", "test/path/2", LinkType.copy, "",
                                               None, False),
                                 LinkOperation("test/path/3", "test/path/3", LinkType.copy, "",
                                               None, False),
                                 LinkOperation("menu/test.json", "menu/test.json",
                                               LinkType.hardlink, "", None, True)])

        self.assertEquals(output, expected_output)