public async Task ParseHtml()
        {
            var logger = new Mock<ILogger>();

            var downloader = new Mock<IAniDbTitleDownloader>();
            downloader.Setup(d => d.Load(It.IsAny<CancellationToken>())).Returns(Task.FromResult(0));
            downloader.Setup(d => d.TitlesFilePath).Returns("TestData/anidb/titles.xml");

            var matcher = new AniDbTitleMatcher(logger.Object, downloader.Object);

            Assert.That(matcher.IsLoaded, Is.False);

            Assert.That(await matcher.FindSeries("CotS"), Is.EqualTo("1"));
            Assert.That(await matcher.FindSeries("Crest of the Stars"), Is.EqualTo("1"));
            Assert.That(await matcher.FindSeries("星界の紋章"), Is.EqualTo("1"));
            Assert.That(await matcher.FindSeries("サザンアイズ"), Is.EqualTo("2"));
            Assert.That(await matcher.FindSeries("3x3 Eyes"), Is.EqualTo("2"));
            Assert.That(await matcher.FindSeries("Sazan Eyes"), Is.EqualTo("2"));

            Assert.That(await matcher.FindSeries("Black Rock Shooter"), Is.EqualTo("6820"));
            Assert.That(await matcher.FindSeries("ブラック★ロックシューター"), Is.EqualTo("6820"));
            Assert.That(await matcher.FindSeries("brs"), Is.EqualTo("6820"));
            Assert.That(await matcher.FindSeries("BLACK★ROCK SHOOTER"), Is.EqualTo("6820"));
            Assert.That(await matcher.FindSeries("Black Rock Shooter (2012)"), Is.EqualTo("8584"));
            Assert.That(await matcher.FindSeries("ブラック★ロックシューター (2012)"), Is.EqualTo("8584"));
        }
        public async Task ErrorLoggedIfTitlesFileMissing()
        {
            var downloader = new Mock<IAniDbTitleDownloader>();
            downloader.Setup(d => d.Load(It.IsAny<CancellationToken>())).Returns(Task.FromResult(0));
            downloader.Setup(d => d.TitlesFilePath).Returns("InvalidPath");

            var logger = new Mock<ILogger>();
            logger.Setup(l => l.ErrorException("Failed to load AniDB titles", It.IsAny<Exception>())).Verifiable();

            var matcher = new AniDbTitleMatcher(logger.Object, downloader.Object);

            await matcher.FindSeries("CotS");

            logger.Verify();
        }