コード例 #1
0
        public async Task GetHistory()
        {
            IEnumerable <ITrack> tracks = await _user.GetHistory();


            Assert.IsNotNull(tracks, nameof(tracks));
            Assert.AreEqual(13, tracks.Count(), "Count");

            var firstTrack = tracks.First();

            Assert.IsNotNull(firstTrack, nameof(firstTrack));
            Assert.AreEqual(85963055, firstTrack.Id, nameof(firstTrack.Id));
            Assert.AreEqual("Waves (Tomorrowland 2014 Anthem) (Radio Edit)", firstTrack.Title, nameof(firstTrack.Title));
        }
コード例 #2
0
        public async Task GetHistory()
        {
            _server.Content = base.GetServerResponse("history");


            IEnumerable <ITrack> tracks = await _user.GetHistory();


            Assert.IsNotNull(tracks, nameof(tracks));
            Assert.AreEqual(50, tracks.Count(), "Count");

            var firstTrack = tracks.First();

            Assert.IsNotNull(firstTrack, nameof(firstTrack));
            Assert.AreEqual(391727202, firstTrack.Id, nameof(firstTrack.Id));
            Assert.AreEqual("Silence", firstTrack.Title, nameof(firstTrack.Title));
        }