#NEWLINE# def testUserInfoRecipeWithExternalGroup( self ) : #NEWLINE# #INDENT# recipestr1 = "\nclass TestUser(UserInfoRecipe):\n    clearBuildReqs()\n    name = 'info-foo'\n    version = '1'\n    def setup(r):\n        r.macros.foo = 'foo'\n        r.macros.bar = 'bar'\n        r.User('%(foo)s', 1000, group='%(bar)s', provideGroup=False)\n" #NEWLINE# self . reset ( ) #NEWLINE# ( built , d ) = self . buildRecipe ( recipestr1 , 'TestUser' , logBuild = True ) #NEWLINE# repos = self . openRepository ( ) #NEWLINE# ( name , version , flavor ) = built [ 0 ] #NEWLINE# version = versions . VersionFromString ( version ) #NEWLINE# trove = repos . getTrove ( trove , version , flavor ) #NEWLINE# pathsFound = [ ] #NEWLINE# for ( pathId , path , fileId , version , fileObj ) in repos . iterFilesInTrove ( trove . getName ( ) , trove . getVersion ( ) , trove . getFlavor ( ) , withFiles = True ) : #NEWLINE# #INDENT# req = str ( fileObj . requires ( ) ) #NEWLINE# prov = str ( fileObj . provides ( ) ) #NEWLINE# pathsFound . append ( path ) #NEWLINE# if ( path == '/etc/conary/userinfo/foo' ) : #NEWLINE# #INDENT# assert ( prov . find ( 'userinfo: foo' ) != ( - 1 ) ) , prov #NEWLINE# assert ( req . find ( 'groupinfo: bar' ) != ( - 1 ) ) , req #NEWLINE# #UNINDENT# #UNINDENT# assert ( '/etc/conary/userinfo/foo' in pathsFound ) , pathsFound