def test_url_shiranai(self): url = 'http://utaten.com/lyric/AAA/Charge+%26++Go%21/' obj = Lyric(url) obj.parse() self.assertEqual(obj.title, u'Charge & Go!') self.assertEqual(obj.artist, u'AAA') self.assertEqual(obj.lyricist, u'Kenn Kato') self.assertEqual(obj.composer, u'TETSUYA KOMURO') self.assertEqual(len(obj.lyric), 1256)
def test_url_guren(self): url = 'http://utaten.com/lyric/BUMP+OF+CHICKEN/beautiful+glider/' obj = Lyric(url) obj.parse() self.assertEqual(obj.title, u'beautiful glider') self.assertEqual(obj.artist, u'BUMP OF CHICKEN') self.assertEqual(obj.lyricist, u'藤原基央') self.assertEqual(obj.composer, u'藤原基央') self.assertEqual(len(obj.lyric), 959)