def testAddRemoveLyrics(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return comment = "Why can't I be you?" for i, (c, d, l) in enumerate([(comment, "c0", None), (comment, "c1", None), (comment, "c2", 'eng'), ("¿Por qué no puedo ser tú ?", "c2", 'esp'), ]): darg = ":{}".format(d) if d else "" larg = ":{}".format(l) if l else "" opts = ["--add-comment={c}{darg}{larg}".format(**locals()), self.test_file] self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) tag_comment = af.tag.comments.get(d or "", lang=utils.b(l if l else "eng")) assert (tag_comment.text == c) assert (tag_comment.description == d or "") assert (tag_comment.lang == utils.b(l if l else "eng")) for d, l in [("c0", None), ("c1", None), ("c2", "eng"), ("c2", "esp"), ]: larg = ":{}".format(l) if l else "" opts = ["--remove-comment={d}{larg}".format(**locals()), self.test_file] self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) tag_comment = af.tag.comments.get(d, lang=utils.b(l if l else "eng")) assert tag_comment is None assert (len(af.tag.comments) == 0)
def testRemoveAllComments(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return comment = u"Why can't I be you?" for i, (c, d, l) in enumerate([ (comment, u"c0", None), (comment, u"c1", None), (comment, u"c2", 'eng'), (u"¿Por qué no puedo ser tú ?", u"c2", 'esp'), (comment, u"c4", "ger"), (comment, u"c4", "rus"), (comment, u"c5", "rus"), ]): darg = u":{}".format(d) if d else "" larg = u":{}".format(l) if l else "" opts = [ u"--add-comment={c}{darg}{larg}".format(**locals()), self.test_file ] self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) tag_comment = af.tag.comments.get(d or u"", lang=compat.b(l if l else "eng")) assert_equal(tag_comment.text, c) assert_equal(tag_comment.description, d or u"") assert_equal(tag_comment.lang, compat.b(l if l else "eng")) opts = [u"--remove-all-comments", self.test_file] self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_equal(len(af.tag.comments), 0)
def testReadEmptyMp3(): with RedirectStdStreams() as out: args, _, config = main.parseCommandLine( [os.path.join(DATA_D, "test.mp3")]) retval = main.main(args, config) assert_equal(retval, 0) assert_not_equal(out.stderr.read().find("No ID3 v1.x/v2.x tag found"), -1)
def testLameInfoPlugin(): test_file = Path(DATA_D) / "mp3_samples/mpeg2.5 12.000kHz __vbr__ simple.mp3" with RedirectStdStreams() as plugin_out: args, _, config = main.parseCommandLine(["-P", "lameinfo", str(test_file)]) retval = main.main(args, config) assert retval == 0 stdout = plugin_out.stdout.read() assert stdout[stdout.index("Encoder Version"):].strip() == \ """ Encoder Version : LAME3.99r LAME Tag Revision : 0 VBR Method : Variable Bitrate method2 (mtrh) Lowpass Filter : 6000 Radio Replay Gain : 12.2 dB (Set automatically) Encoding Flags : --nspsytune --nssafejoint ATH Type : 5 Bitrate (Minimum) : 8 Encoder Delay : 576 samples Encoder Padding : 960 samples Noise Shaping : 1 Stereo Mode : Stereo Unwise Settings : False Sample Frequency : 44.1 kHz MP3 Gain : 0 (+0.0 dB) Preset : V0 Surround Info : None Music Length : 67.88 KB Music CRC-16 : 8707 LAME Tag CRC-16 : 0000 """.strip()
def testReadEmptyMp3(): with RedirectStdStreams() as out: args, _, config = main.parseCommandLine([os.path.join(DATA_D, "test.mp3")]) retval = main.main(args, config) assert retval == 0 assert out.stderr.read().find("No ID3 v1.x/v2.x tag found") != -1
def func(audiofile, args, expected_retval=0, reload_version=None): try: args, _, config = main.parseCommandLine(args + [audiofile.path]) retval = main.main(args, config) except SystemExit as sys_exit: retval = sys_exit.code assert retval == expected_retval return eyed3.load(audiofile.path, tag_version=reload_version)
def _eyeD3(audiofile, args, expected_retval=0): try: args, _, config = main.parseCommandLine(args + [audiofile.path]) retval = main.main(args, config) except SystemExit as exit: retval = exit.code assert retval == expected_retval return eyed3.load(audiofile.path)
def func(audiofile, args, expected_retval=0, reload_version=None): try: args, _, config = main.parseCommandLine(args + [audiofile.path]) retval = main.main(args, config) except SystemExit as exit: retval = exit.code assert retval == expected_retval return eyed3.load(audiofile.path, tag_version=reload_version)
def testUniqueFileId_N(self): # Add 3 with RedirectStdStreams() as out: assert out args, _, config = \ main.parseCommandLine(["--unique-file-id", "Travis:Me", "--unique-file-id=Engine:Kid", "--unique-file-id", "Owner:Kid", self.test_file]) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert len(af.tag.unique_file_ids) == 3 assert af.tag.unique_file_ids.get("Travis").uniq_id == b"Me" assert af.tag.unique_file_ids.get("Engine").uniq_id == b"Kid" assert af.tag.unique_file_ids.get(b"Owner").uniq_id == b"Kid" # Remove 2 with RedirectStdStreams() as out: assert out args, _, config = \ main.parseCommandLine(["--unique-file-id", "Travis:", "--unique-file-id=Engine:", "--unique-file-id", "Owner:Kid", self.test_file]) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert len(af.tag.unique_file_ids) == 1 # Remove not found ID with RedirectStdStreams() as out: args, _, config = \ main.parseCommandLine(["--unique-file-id", "Travis:", self.test_file]) retval = main.main(args, config) assert retval == 0 sout = out.stdout.read() assert "Unique file ID 'Travis' not found" in sout af = eyed3.load(self.test_file) assert len(af.tag.unique_file_ids) == 1
def _runPlugin(afile, plugin) -> str: with RedirectStdStreams() as plugin_out: args, _, config = main.parseCommandLine( ["-P", plugin, str(afile.path)]) assert main.main(args, config) == 0 stdout = plugin_out.stdout.read().strip() print(stdout) return stdout
def testLameInfoPlugin_None(): test_file = Path(DATA_D) / "test.mp3" with RedirectStdStreams() as plugin_out: args, _, config = main.parseCommandLine(["-P", "lameinfo", str(test_file)]) retval = main.main(args, config) assert retval == 0 stdout = plugin_out.stdout.read() assert stdout[stdout.index("--\n") + 3:].strip() == "No LAME Tag"
def testUniqueFileId_1(self): with RedirectStdStreams() as out: assert out args, _, config = main.parseCommandLine(["--unique-file-id", "Travis:Me", self.test_file]) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert len(af.tag.unique_file_ids) == 1 assert af.tag.unique_file_ids.get(b"Travis").uniq_id == b"Me"
def testNewTagComposer(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["--composer=H.R.", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert af is not None assert af.tag is not None assert af.tag.composer == "H.R."
def testNewTagNonStdGenre(self, version=id3.ID3_DEFAULT_VERSION): for opts in (("-G", "108", "--non-std-genre", self.test_file), ("--genre=108", "--non-std-genre", self.test_file)): self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert af.tag.non_std_genre.name == "108" assert af.tag.non_std_genre.id is None
def testNewTagOrigRelease(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["--orig-release-date=1981", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.original_release_date.year, 1981)
def testNewTagOrigRelease(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["--orig-release-date=1981", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.original_release_date.year == 1981)
def testNewTagAlbum(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-A", "Psychedelic Jungle", self.test_file], ["--album=Psychedelic Jungle", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.album == "Psychedelic Jungle")
def testNewTagArtist(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["-a", "The Cramps", self.test_file], ["--artist=The Cramps", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.artist, u"The Cramps")
def testNewTagTrackNum(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-n", "14", self.test_file], ["--track=14", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.track_num[0] == 14)
def testNewTagTitle(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["-t", "Green Door", self.test_file], ["--title=Green Door", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.title, u"Green Door")
def testNewTagAlbumArtist(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-b", "Various Artists", self.test_file], ["--album-artist=Various Artists", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert af is not None assert af.tag is not None assert af.tag.album_artist == "Various Artists"
def testNewTagAlbumArtist(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-b", "Various Artists", self.test_file], ["--album-artist=Various Artists", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert af is not None assert af.tag is not None assert af.tag.album_artist == u"Various Artists"
def testNewTagArtist(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-a", "The Cramps", self.test_file], ["--artist=The Cramps", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert retval == 0 af = eyed3.load(self.test_file) assert af is not None assert af.tag is not None assert af.tag.artist == "The Cramps"
def testNewTagTrackNum(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["-n", "14", self.test_file], ["--track=14", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.track_num[0], 14)
def testNewTagTitle(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-t", "Green Door", self.test_file], ["--title=Green Door", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.title == "Green Door")
def testNewTagAlbum(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["-A", "Psychedelic Jungle", self.test_file], ["--album=Psychedelic Jungle", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.album, u"Psychedelic Jungle")
def testNewTagPublisher(self): for expected, opts in [ ("SST", ["--publisher", "SST", self.test_file]), ("Dischord", ["--publisher=Dischord", self.test_file]), ]: with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.publisher, expected)
def testNewTagGenre(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["-G", "Rock", self.test_file], ["--genre=Rock", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.genre.name, "Rock") assert_equal(af.tag.genre.id, 17)
def testNewTagRecordingDate(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["--recording-date=1993-10-30", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.recording_date.year, 1993) assert_equal(af.tag.recording_date.month, 10) assert_equal(af.tag.recording_date.day, 30)
def testNewTagRecordingDate(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["--recording-date=1993-10-30", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.recording_date.year == 1993) assert (af.tag.recording_date.month == 10) assert (af.tag.recording_date.day == 30)
def testNewTagPublisher(self): for expected, opts in [ ("SST", ["--publisher", "SST", self.test_file]), ("Dischord", ["--publisher=Dischord", self.test_file]), ]: with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.publisher == expected)
def testNewTagGenre(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-G", "Rock", self.test_file], ["--genre=Rock", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.genre.name == "Rock") assert (af.tag.genre.id == 17)
def testNewTagReleaseDate(self, version=id3.ID3_DEFAULT_VERSION): for date in ["1981", "1981-03-06", "1981-03"]: orig_date = core.Date.parse(date) for opts in [["--release-date=%s" % str(date), self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.release_date, orig_date)
def testNewTagReleaseDate(self, version=id3.ID3_DEFAULT_VERSION): for date in ["1981", "1981-03-06", "1981-03"]: orig_date = core.Date.parse(date) for opts in [ ["--release-date=%s" % str(date), self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.release_date == orig_date)
def testNewTagBpm(self): for expected, opts in [ (1, ["--bpm=1", self.test_file]), (180, ["--bpm=180", self.test_file]), (117, ["--bpm", "116.7", self.test_file]), (116, ["--bpm", "116.4", self.test_file]), ]: with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.bpm == expected)
def testNewTagYear(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["-Y", "1981", self.test_file], ["--release-year=1981", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) if version == id3.ID3_V2_3: assert (af.tag.original_release_date.year == 1981) else: assert (af.tag.release_date.year == 1981)
def testNewTagEncodingDate(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["--encoding-date=2012-10-23T20:22", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.encoding_date.year == 2012) assert (af.tag.encoding_date.month == 10) assert (af.tag.encoding_date.day == 23) assert (af.tag.encoding_date.hour == 20) assert (af.tag.encoding_date.minute == 22)
def testNewTagPlayCount(self): for expected, opts in [ (0, ["--play-count=0", self.test_file]), (1, ["--play-count=+1", self.test_file]), (6, ["--play-count=+5", self.test_file]), (7, ["--play-count=7", self.test_file]), (10000, ["--play-count=10000", self.test_file]), ]: with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.play_count == expected)
def testNewTagTaggingDate(self, version=id3.ID3_DEFAULT_VERSION): for opts in [ ["--tagging-date=2012-10-23T20:22", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.tagging_date.year == 2012) assert (af.tag.tagging_date.month == 10) assert (af.tag.tagging_date.day == 23) assert (af.tag.tagging_date.hour == 20) assert (af.tag.tagging_date.minute == 22)
def testNewTagTaggingDate(self, version=id3.ID3_DEFAULT_VERSION): for opts in [["--tagging-date=2012-10-23T20:22", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.tagging_date.year, 2012) assert_equal(af.tag.tagging_date.month, 10) assert_equal(af.tag.tagging_date.day, 23) assert_equal(af.tag.tagging_date.hour, 20) assert_equal(af.tag.tagging_date.minute, 22)
def testNewTagTrackTotal(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return for opts in [ ["-N", "14", self.test_file], ["--track-total=14", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.track_num[1] == 14)
def testNewTagTrackTotal(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return for opts in [["-N", "14", self.test_file], ["--track-total=14", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.track_num[1], 14)
def testNewTagSimpleComment(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return for opts in [["-c", "Starlette", self.test_file], ["--comment=Starlette", self.test_file]]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert_equal(retval, 0) af = eyed3.load(self.test_file) assert_is_not_none(af) assert_is_not_none(af.tag) assert_equal(af.tag.comments[0].text, "Starlette") assert_equal(af.tag.comments[0].description, "")
def testNewTagSimpleComment(self, version=id3.ID3_DEFAULT_VERSION): if version[0] == 1: # No support for this in v1.x return for opts in [ ["-c", "Starlette", self.test_file], ["--comment=Starlette", self.test_file] ]: self._addVersionOpt(version, opts) with RedirectStdStreams() as out: args, _, config = main.parseCommandLine(opts) retval = main.main(args, config) assert (retval == 0) af = eyed3.load(self.test_file) assert (af is not None) assert (af.tag is not None) assert (af.tag.comments[0].text == "Starlette") assert (af.tag.comments[0].description == "")