コード例 #1
0
        public void CreateTest()
        {
            var frame = new UrlLinkFrame("W123", "URL");

            Assert.AreEqual(frame.Descriptor.Id, "W123");
            Assert.AreEqual(frame.Url, "URL");
        }
コード例 #2
0
        public void ConverterISO88591_Test()
        {
            var urlLinkFrame = new UrlLinkFrame
                                   {
                                       Url = "ABCD",
                                       Descriptor = {Id = "W123"}
                                   };

            RawFrame rawFrame = urlLinkFrame.Convert(TagVersion.Id3V23);

            Assert.AreEqual(rawFrame.Id, "W123");
            Assert.AreEqual(rawFrame.Payload.Count, 4);
            var refBytes = new byte[] {0x41, 0x42, 0x43, 0x44};
            Assert.IsTrue(ComparePayload(rawFrame.Payload, refBytes));
        }