public void TestGetPiecesInfoHashWithNoParseOnMetaInfoFile() { MetaInfoFile torrentFile = new MetaInfoFile(Constants.SingleFileTorrent); BitTorrentException error = Assert.Throws <BitTorrentException>(() => { byte[] piecesInfoHash = torrentFile.GetPiecesInfoHash(); }); Assert.Equal("BitTorrent Error: File has not been parsed.", error.Message); }