public async Task EncodeTest1()
        {
            fileSystem.EnumFileSystemEntriesFunc = _ => new FileSystemEntry[0];

            streamBuilder.Trace = string.Empty;
            await service.EncodeAsync(@"C:\dir\", "file.dat", CancellationToken.None, null);

            Assert.AreEqual("->Initialize;->AddWeightsTable;", streamBuilder.Trace);
        }
 public void EncodeGuardCase1Test()
 {
     Assert.ThrowsAsync <ArgumentNullException>(async() => await service.EncodeAsync(null, "file", CancellationToken.None, null));
 }