def test_format(self): tags = {'artist': 'Bob Marley', 'title': 'One Love'} template = FreiTemplate(' %artist - %title ') self.assertEquals('Bob Marley - One Love', template.format(tags))
def run(self, args): songs = self.get_songs(args.files) template = FreiTemplate(args.format) for song in songs: print template.format(song)
def test_format(self): tags = {'artist': 'Bob Marley', 'title': 'One Love'} template = FreiTemplate(' %artist - %title ') self.assertEquals('Bob Marley - One Love', template.format(tags))