#NEWLINE# def testInstallRemap( self ) : #NEWLINE# #INDENT# recipestr1 = "\nclass RenamedInstalls(PackageRecipe):\n    name = 'test'\n    version = '0'\n    clearBuildReqs()\n\n    def setup(self):\n        # these files should end up in the foo package (CNY-1679)\n        # we're looking to prove that Install followed a PackageSpec through\n        # the path translation process\n        self.addSource('sourcefile')\n        self.Install('sourcefile', '/foo', package = 'foo')\n" #NEWLINE# self . addPolicy ( renamePolicy ) #NEWLINE# ( built , d ) = self . buildRecipe ( recipestr1 , 'RenamedInstalls' ) #NEWLINE# self . assertEquals ( len ( built ) , 1 ) #NEWLINE# self . assertEquals ( built [ 0 ] [ 0 ] , 'foo:runtime' ) #NEWLINE# repos = self . openRepository ( ) #NEWLINE# trvNVF = repos . findTrove ( None , built [ 0 ] ) #NEWLINE# trv = repos . getTrove ( * trvNVF [ 0 ] ) #NEWLINE# fileInfo = [ x for x in trv . iterFileList ( ) ] [ 0 ] #NEWLINE# self . assertEquals ( fileInfo [ 1 ] , '/foo-1' )